From 0011df47bcb0b3c2811046be54ba150bcd3e06cc Mon Sep 17 00:00:00 2001 From: Pete Cordell Date: Mon, 5 Aug 2024 15:30:15 +0100 Subject: [PATCH] ws: flags to opcodes should ignore CURLWS_CONT flag When converting WebSocket flags such as CURLWS_TEXT | CURLWS_CONT we want to exclude CURLWS_CONT from the lookup. Closes #14397 --- lib/ws.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/ws.c b/lib/ws.c index 3e8a4e818e..5854e5a5d3 100644 --- a/lib/ws.c +++ b/lib/ws.c @@ -560,7 +560,7 @@ static ssize_t ws_enc_write_head(struct Curl_easy *data, return -1; } - opcode = ws_frame_flags2op((int)flags); + opcode = ws_frame_flags2op((int)flags & ~CURLWS_CONT); if(!opcode) { failf(data, "WS: provided flags not recognized '%x'", flags); *err = CURLE_SEND_ERROR;