We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent aaff427 commit 96fd212Copy full SHA for 96fd212
1 file changed
libs/server-sent-events/src/curl_client.hpp
@@ -101,6 +101,12 @@ class CurlClient final : public Client,
101
// status line, emitted on the empty terminator line.
102
http::response_header<> current_response;
103
104
+ // True while accumulating headers between an `HTTP/` status line and
105
+ // the empty terminator. Gates `HeaderCallback` against chunked
106
+ // trailers (which arrive without a fresh status line) and against
107
+ // interior `HTTP/` lines that would otherwise wipe accumulated state.
108
+ bool reading_headers = false;
109
+
110
// Mutated on the strand in do_run() before each transfer, and read by
111
// libcurl via raw pointers (CURLOPT_URL, CURLOPT_POSTFIELDS) for the
112
// duration of the transfer. Safe because the next do_run() only fires
0 commit comments