From 6a0dc7cf23cae900b75b2c133fb9f9bfab6e2b1e Mon Sep 17 00:00:00 2001 From: Dmitry Karpov Date: Wed, 29 Nov 2023 12:49:06 -0800 Subject: [PATCH] transfer: abort pause send when connection is marked for closing This handles cases of some bi-directional "upgrade" scenarios (i.e. WebSockets) where sending is paused until some "upgrade" handshake is completed, but server rejects the handshake and closes the connection. Closes #12428 --- lib/transfer.c | 1 + 1 file changed, 1 insertion(+) diff --git a/lib/transfer.c b/lib/transfer.c index e7158aa3ab..96f1fde755 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -733,6 +733,7 @@ static CURLcode readwrite_data(struct Curl_easy *data, on from our side, we need to stop that immediately. */ infof(data, "we are done reading and this is set to close, stop send"); k->keepon &= ~KEEP_SEND; /* no writing anymore either */ + k->keepon &= ~KEEP_SEND_PAUSE; /* no pausing anymore either */ } out: -- 2.47.3