]> granicus.if.org Git - curl/commitdiff
multi: call multi_done on connect timeouts
authorDaniel Stenberg <daniel@haxx.se>
Sun, 24 Feb 2019 15:32:04 +0000 (16:32 +0100)
committerDaniel Stenberg <daniel@haxx.se>
Sun, 24 Feb 2019 21:56:46 +0000 (22:56 +0100)
Failing to do so would make the CURLINFO_TOTAL_TIME timeout to not get
updated correctly and could end up getting reported to the application
completely wrong (way too small).

Reported-by: accountantM on github
Fixes #3602
Closes #3605

lib/multi.c

index 521262b2b26712a26370cce5b707ace5a426de00..06aaed26a807fed7e424f5b40885644ddd834039 100644 (file)
@@ -1606,7 +1606,8 @@ static CURLMcode multi_runsingle(struct Curl_multi *multi,
       }
       else if(result) {
         /* failure detected */
-        /* Just break, the cleaning up is handled all in one place */
+        Curl_posttransfer(data);
+        multi_done(data, result, TRUE);
         stream_error = TRUE;
         break;
       }