mirror of
https://github.com/oven-sh/bun
synced 2026-02-09 10:28:47 +00:00
we need to close at some point
This commit is contained in:
@@ -1069,6 +1069,11 @@ pub fn writeToStream(this: *HTTPClient, comptime is_ssl: bool, socket: NewHTTPCo
|
||||
this.state.request_stage = .done;
|
||||
stream_buffer.release();
|
||||
stream.detach();
|
||||
if (this.flags.upgrade_state == .upgraded) {
|
||||
this.state.flags.received_last_chunk = true;
|
||||
// upgraded connection will end when the body is done (no half-open connections)
|
||||
this.progressUpdate(is_ssl, if (is_ssl) &http_thread.https_context else &http_thread.http_context, socket);
|
||||
}
|
||||
} else {
|
||||
// only report drain if we send everything and previous we had something to send
|
||||
if (!wasEmpty) {
|
||||
|
||||
Reference in New Issue
Block a user