aboutsummaryrefslogtreecommitdiff
path: root/lib/transfer.c
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2001-11-02 22:30:34 +0000
committerDaniel Stenberg <daniel@haxx.se>2001-11-02 22:30:34 +0000
commit4163b86cd2562dbffaea1541b0ec9e7c982a0dda (patch)
tree8799b8fe3b2d3843e520ec91df996961fc522ba4 /lib/transfer.c
parent5b948512f94917feb23baef307e269f6aed115d9 (diff)
failf() now only overwrites the error buffer the first time it gets called
for each *_perform(). It makes things a lot easier, as the first one that detects the error get to write the final error reason...
Diffstat (limited to 'lib/transfer.c')
-rw-r--r--lib/transfer.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/transfer.c b/lib/transfer.c
index 28fbf702d..449b2e6eb 100644
--- a/lib/transfer.c
+++ b/lib/transfer.c
@@ -863,7 +863,7 @@ Transfer(struct connectdata *c_conn)
}
if (data->set.timeout &&
- ((Curl_tvdiff(now, start)/1000) > data->set.timeout)) {
+ ((Curl_tvdiff(now, start)/1000) >= data->set.timeout)) {
failf (data, "Operation timed out with %d out of %d bytes received",
bytecount, conn->size);
return CURLE_OPERATION_TIMEOUTED;
@@ -914,6 +914,7 @@ CURLcode Curl_perform(struct SessionHandle *data)
data->set.followlocation=0; /* reset the location-follow counter */
data->state.this_is_a_follow = FALSE; /* reset this */
+ data->state.errorbuf = FALSE; /* no error has occurred */
Curl_initinfo(data); /* reset session-specific information "variables" */