diff options
author | Curl Upstream <curl-library@cool.haxx.se> | 2020-03-04 06:31:59 (GMT) |
---|---|---|
committer | Brad King <brad.king@kitware.com> | 2020-03-04 19:34:23 (GMT) |
commit | 735ea3001ae98636a4cb7caf15a40960c0da39a1 (patch) | |
tree | dc511f0892ccd186358795757e9abb23aa567e1d /lib/pingpong.c | |
parent | b26487c663ec29d972fd61adc2b14ac5880b78c7 (diff) | |
download | CMake-735ea3001ae98636a4cb7caf15a40960c0da39a1.zip CMake-735ea3001ae98636a4cb7caf15a40960c0da39a1.tar.gz CMake-735ea3001ae98636a4cb7caf15a40960c0da39a1.tar.bz2 |
curl 2020-03-04 (b8d13668)
Code extracted from:
https://github.com/curl/curl.git
at commit b8d1366852fd0034374c5de1e4968c7a224f77cc (curl-7_69_0).
Diffstat (limited to 'lib/pingpong.c')
-rw-r--r-- | lib/pingpong.c | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/lib/pingpong.c b/lib/pingpong.c index e9568ee..d071005 100644 --- a/lib/pingpong.c +++ b/lib/pingpong.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2018, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2019, Daniel Stenberg, <daniel@haxx.se>, et al. * * This software is licensed as described in the file COPYING, which * you should have received as part of this distribution. The terms @@ -60,12 +60,12 @@ time_t Curl_pp_state_timeout(struct pingpong *pp, bool disconnecting) /* Without a requested timeout, we only wait 'response_time' seconds for the full response to arrive before we bail out */ timeout_ms = response_time - - Curl_timediff(Curl_now(), pp->response); /* spent time */ + (time_t)Curl_timediff(Curl_now(), pp->response); /* spent time */ if(data->set.timeout && !disconnecting) { /* if timeout is requested, find out how much remaining time we have */ time_t timeout2_ms = data->set.timeout - /* timeout time */ - Curl_timediff(Curl_now(), conn->now); /* spent time */ + (time_t)Curl_timediff(Curl_now(), conn->now); /* spent time */ /* pick the lowest number */ timeout_ms = CURLMIN(timeout_ms, timeout2_ms); @@ -463,14 +463,9 @@ CURLcode Curl_pp_readresp(curl_socket_t sockfd, } int Curl_pp_getsock(struct pingpong *pp, - curl_socket_t *socks, - int numsocks) + curl_socket_t *socks) { struct connectdata *conn = pp->conn; - - if(!numsocks) - return GETSOCK_BLANK; - socks[0] = conn->sock[FIRSTSOCKET]; if(pp->sendleft) { |