+ /* when retrieving from http-proxy wget sometimes does not trust the
+ * file length reported by server.
+ * this check is to tell wget not to stubbornly try to read again and
+ * again until another errno code was received. */
+ if ( ret == -1 && errno == ETIMEDOUT && sum_read == toread && toread > 0 )
+ break;
+