diff options
author | Daniel Stenberg <daniel@haxx.se> | 2014-01-05 16:38:18 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2014-01-12 00:11:53 +0100 |
commit | 3b183df9cc781b329ca409ded1ea336530624715 (patch) | |
tree | cd335d59f73dd0ec90682ab39b0438a8959bec1e /lib/transfer.c | |
parent | 7cd45b297ec2d09af92cd6defccd54c7e9ac5a3d (diff) | |
download | curl-3b183df9cc781b329ca409ded1ea336530624715.tar.gz |
multi: remove MULTI_TIMEOUT_INACCURACY
With the recently added timeout "reminder" functionality, there's no
reason left for us to execute timeout code before the time is
ripe. Simplifies the handling too.
This will make the *TIMEOUT and *CONNECTTIMEOUT options more accurate
again, which probably is most important when the *_MS versions are used.
In multi_socket, make sure to update 'now' after having handled activity
on a socket.
Diffstat (limited to 'lib/transfer.c')
-rw-r--r-- | lib/transfer.c | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/lib/transfer.c b/lib/transfer.c index 7861174a7..3408a8414 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2013, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2014, 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 @@ -1320,11 +1320,10 @@ CURLcode Curl_pretransfer(struct SessionHandle *data) Curl_pgrsStartNow(data); if(data->set.timeout) - Curl_expire(data, data->set.timeout + MULTI_TIMEOUT_INACCURACY_MS); + Curl_expire(data, data->set.timeout); if(data->set.connecttimeout) - Curl_expire(data, data->set.connecttimeout + - MULTI_TIMEOUT_INACCURACY_MS); + Curl_expire(data, data->set.connecttimeout); /* In case the handle is re-used and an authentication method was picked in the session we need to make sure we only use the one(s) we now @@ -1970,8 +1969,7 @@ Curl_setup_transfer( /* Set a timeout for the multi interface. Add the inaccuracy margin so that we don't fire slightly too early and get denied to run. */ - Curl_expire(data, CURL_TIMEOUT_EXPECT_100 + - MULTI_TIMEOUT_INACCURACY / 1000); + Curl_expire(data, CURL_TIMEOUT_EXPECT_100); } else { if(data->state.expect100header) |