diff options
author | Daniel Stenberg <daniel@haxx.se> | 2017-07-29 16:35:09 +0200 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2017-07-29 16:35:09 +0200 |
commit | 0bd2d077afbac413d52980a943cf4ac241956a7a (patch) | |
tree | d0bb92cbcc2fe85c2fb1f9e13df2b76be28cf8f9 /lib/tftp.c | |
parent | 171f8ded26d2845ef358c62f6e95ec34468349ae (diff) | |
download | curl-bagder/now-remade.tar.gz |
now: update 'now' as part of the easy handle instead of local variablesbagder/now-remade
... as the mix of both passing in current time and figuring it out
locally sometimes made "now" move in time in unexpected ways.
Curl_timeleft() got an updated prototype. The old defines for
Curl_tvnow() and Curl_tvdiff() are now removed.
Renamed the conn->new member to setup_time and fixed its use somewhat.
Moved the 'now' field from the SingleRequest struct within the easy
handle to the struct UrlState.
Diffstat (limited to 'lib/tftp.c')
-rw-r--r-- | lib/tftp.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/tftp.c b/lib/tftp.c index 336beb512..b54488c24 100644 --- a/lib/tftp.c +++ b/lib/tftp.c @@ -5,7 +5,7 @@ * | (__| |_| | _ <| |___ * \___|\___/|_| \_\_____| * - * Copyright (C) 1998 - 2016, Daniel Stenberg, <daniel@haxx.se>, et al. + * Copyright (C) 1998 - 2017, 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 @@ -206,7 +206,7 @@ static CURLcode tftp_set_timeouts(tftp_state_data_t *state) time(&state->start_time); /* Compute drop-dead time */ - timeout_ms = Curl_timeleft(state->conn->data, NULL, start); + timeout_ms = Curl_timeleft(state->conn->data, start); if(timeout_ms < 0) { /* time-out, bail out, go home */ @@ -1287,7 +1287,7 @@ static CURLcode tftp_doing(struct connectdata *conn, bool *dophase_done) if(Curl_pgrsUpdate(conn)) result = CURLE_ABORTED_BY_CALLBACK; else - result = Curl_speedcheck(conn->data, Curl_tvnow()); + result = Curl_speedcheck(conn->data, curlx_tvnow()); } return result; } |