diff options
Diffstat (limited to 'lib/pingpong.c')
-rw-r--r-- | lib/pingpong.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/lib/pingpong.c b/lib/pingpong.c index c6b6f2f..876a6a2 100644 --- a/lib/pingpong.c +++ b/lib/pingpong.c @@ -322,7 +322,7 @@ CURLcode Curl_pp_readresp(curl_socket_t sockfd, */ DEBUGASSERT((ptr+pp->cache_size) <= (buf+BUFSIZE+1)); memcpy(ptr, pp->cache, pp->cache_size); - gotbytes = pp->cache_size; + gotbytes = (ssize_t)pp->cache_size; free(pp->cache); /* free the cache */ pp->cache = NULL; /* clear the pointer */ pp->cache_size = 0; /* zero the size just in case */ @@ -340,8 +340,7 @@ CURLcode Curl_pp_readresp(curl_socket_t sockfd, #if defined(HAVE_KRB4) || defined(HAVE_GSSAPI) conn->data_prot = prot; #endif - if(res < 0) - /* EWOULDBLOCK */ + if(res == CURLE_AGAIN) return CURLE_OK; /* return */ #ifdef CURL_DOES_CONVERSIONS @@ -387,8 +386,8 @@ CURLcode Curl_pp_readresp(curl_socket_t sockfd, if(!conn->sec_complete) #endif if(data->set.verbose) - Curl_debug(data, CURLINFO_HEADER_IN, - pp->linestart_resp, (size_t)perline, conn); + Curl_debug(data, CURLINFO_HEADER_IN, + pp->linestart_resp, (size_t)perline, conn); /* * We pass all response-lines to the callback function registered |