From: Yang Tse Date: Fri, 27 Oct 2006 02:18:29 +0000 (+0000) Subject: Compiler warning fix X-Git-Tag: curl-7_16_0~13 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=8a7514de8ace5dcb9fe322043cc7cfe5372646dd;p=thirdparty%2Fcurl.git Compiler warning fix --- diff --git a/lib/socks.c b/lib/socks.c index fb6f7fe25b..3319e697e0 100644 --- a/lib/socks.c +++ b/lib/socks.c @@ -71,25 +71,29 @@ static int blockread_all(struct connectdata *conn, /* connection data */ conntime = Curl_tvdiff(tvnow, conn->created); if(conntime > conn_timeout) { /* we already got the timeout */ - return -1; + result = ~CURLE_OK; + break; } if(Curl_select(sockfd, CURL_SOCKET_BAD, (int)(conn_timeout - conntime)) <= 0) { - return -1; + result = ~CURLE_OK; + break; } result = Curl_read(conn, sockfd, buf, buffersize, &nread); if(result) - return result; + break; if(buffersize == nread) { allread += nread; *n = allread; - return CURLE_OK; + result = CURLE_OK; + break; } buffersize -= nread; buf += nread; allread += nread; } while(1); + return result; } /*