[PATCH setup 11/11] Use wininet for fetching URLs in direct (non-proxy) case (DO NOT APPLY)

Jon Turney jon.turney@dronecode.org.uk
Mon May 1 20:45:00 GMT 2017


On 01/05/2017 16:30, Ã
ke Rehnman wrote:
> Hello,
>
> I tested with my repo and it seem to fail if there is no setup.xz but
> only setup.ini. It does quickly realize there are no setup.xz and
> setup.xz.sig but then it takes forever to get past setup.bz2 etc and
> fails to download setup.ini
>
> These tests were done with -X flag.

Thanks very much for testing this.

It seems this could be an existing bug which could have been triggered 
the proxy case.

The attached incremental patch fixed this for me.
-------------- next part --------------
From a30dab3f8c9081d922b7287801b882001077ddeb Mon Sep 17 00:00:00 2001
From: Jon Turney <jon.turney@dronecode.org.uk>
Date: Mon, 1 May 2017 21:40:40 +0100
Subject: [PATCH setup] Close rather than leak InternetOpenUrl() handles with
 errors

---
 nio-ie5.cc | 1 +
 1 file changed, 1 insertion(+)

diff --git a/nio-ie5.cc b/nio-ie5.cc
index 3375c04..ba19ffa 100644
--- a/nio-ie5.cc
+++ b/nio-ie5.cc
@@ -122,6 +122,7 @@ try_again:
 	    }
 	  else if (type >= 300)
 	    {
+	      InternetCloseHandle (connection);
 	      connection = 0;
 	      return;
 	    }
-- 
2.12.2



More information about the Cygwin-apps mailing list