diff options
author | Daniel Stenberg <daniel@haxx.se> | 2021-01-11 10:01:49 +0100 |
---|---|---|
committer | Daniel Stenberg <daniel@haxx.se> | 2021-01-11 12:33:11 +0100 |
commit | 48220f7e3d4431879602f8d3bf231bf6f635ca79 (patch) | |
tree | 21a3fec47348a2c8603f5981cea02308e8f720d8 /lib/multi.c | |
parent | 057cb05b4bb6dfbd52c204e0627e4bd7efa57347 (diff) | |
download | curl-48220f7e3d4431879602f8d3bf231bf6f635ca79.tar.gz |
multi: skip DONE state if there's no connection left for ftp wildcard
... to avoid running in that state with data->conn being NULL.
Diffstat (limited to 'lib/multi.c')
-rw-r--r-- | lib/multi.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/multi.c b/lib/multi.c index d3863c1e9..a40db6bd8 100644 --- a/lib/multi.c +++ b/lib/multi.c @@ -1916,7 +1916,10 @@ static CURLMcode multi_runsingle(struct Curl_multi *multi, if(wc->state == CURLWC_DONE || wc->state == CURLWC_SKIP) { /* skip some states if it is important */ multi_done(data, CURLE_OK, FALSE); - multistate(data, CURLM_STATE_DONE); + + /* if there's no connection left, skip the DONE state */ + multistate(data, data->conn ? + CURLM_STATE_DONE : CURLM_STATE_COMPLETED); rc = CURLM_CALL_MULTI_PERFORM; break; } |