1
0
mirror of https://github.com/moparisthebest/curl synced 2024-08-13 17:03:50 -04:00

http2: don't close connection when single transfer is stopped

Fixes #2237
Closes #2249
This commit is contained in:
Kartik Mahajan 2018-01-18 22:28:59 +05:30 committed by Daniel Stenberg
parent 87ddeee59b
commit a5e6d6ebcb
No known key found for this signature in database
GPG Key ID: 5CC908FDB71E12C2

View File

@ -581,7 +581,8 @@ static CURLcode multi_done(struct connectdata **connp,
&& !(conn->ntlm.state == NTLMSTATE_TYPE2 ||
conn->proxyntlm.state == NTLMSTATE_TYPE2)
#endif
) || conn->bits.close || premature) {
) || conn->bits.close
|| (premature && !(conn->handler->flags & PROTOPT_STREAM))) {
CURLcode res2 = Curl_disconnect(conn, premature); /* close connection */
/* If we had an error already, make sure we return that one. But