bug-wget
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Bug-wget] GNU wget 1.15 released


From: Gisle Vanem
Subject: Re: [Bug-wget] GNU wget 1.15 released
Date: Thu, 23 Jan 2014 15:06:47 +0100

"Ray Satiro" <address@hidden> wrote:

wget -d  https://encrypted.google.com
..
Yeah I'm getting a flood of that when I -d https
seconds 900.00, Winsock error: 0
seconds 900.00, Winsock error: 0
seconds 900.00, Winsock error: 0
seconds 900.00, Winsock error: 0
seconds 900.00, Winsock error: 0
seconds 900.00, Winsock error: 0
seconds 900.00, Winsock error: 0
over and over

I've figured out this "bug" or annoyance. In case of google.com, it has lots of
IPs (11 now). Wget seems to connect or do something for each of these IPs using run_with_timeout(). In any case, there are no errors in those spawned threads. I originally wrote 'run_with_timeout()' for Windows back in 2003 and used 'struct thread_data' to pass back the Winsock error-codes which are per thread. When 'thread_arg.ws_error' is 0, the debug-message should not be printed. Hence
this diff should fix it:

--- orig/src/mswindows.c 2013-11-18 16:31:41 +0000
+++ src/mswindows.c    2014-01-23 13:48:27 +0000
@@ -559,7 +559,10 @@
      /* Propagate error state (which is per-thread) to this thread,
         so the caller can inspect it.  */
      WSASetLastError (thread_arg.ws_error);
+      if (thread_arg.ws_error)
      DEBUGP (("Winsock error: %d\n", WSAGetLastError ()));
+      else
+         DEBUGP (("\n"));
      rc = false;
    }
  else

----------

--gv



reply via email to

[Prev in Thread] Current Thread [Next in Thread]