]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
if we read zero bytes from the proxy, the connection is broken and we need
authorDaniel Stenberg <daniel@haxx.se>
Tue, 5 Jun 2007 13:42:23 +0000 (13:42 +0000)
committerDaniel Stenberg <daniel@haxx.se>
Tue, 5 Jun 2007 13:42:23 +0000 (13:42 +0000)
to bail out

lib/socks.c

index 6b95e752d61dc0e4bdded9ffe828a7fe18850c57..e1ad86cc0dfccdb14fcf04b6397b34c6f53e99fa 100644 (file)
@@ -98,6 +98,11 @@ static int blockread_all(struct connectdata *conn, /* connection data */
       result = CURLE_OK;
       break;
     }
+    if(!nread) {
+      result = ~CURLE_OK;
+      break;
+    }
+
     buffersize -= nread;
     buf += nread;
     allread += nread;