From 8b49af30bece3a04fe3dca5964356e1bcf360e90 Mon Sep 17 00:00:00 2001 From: Bryan Roe Date: Fri, 19 Aug 2022 16:25:28 -0700 Subject: [PATCH] Backed out change that prevented a disconnect from propagating correctly. --- microscript/ILibDuktape_HttpStream.c | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/microscript/ILibDuktape_HttpStream.c b/microscript/ILibDuktape_HttpStream.c index e9d3049..86cfd4b 100644 --- a/microscript/ILibDuktape_HttpStream.c +++ b/microscript/ILibDuktape_HttpStream.c @@ -4653,18 +4653,6 @@ void ILibDuktape_httpStream_webSocket_DecodedEndSink(ILibDuktape_DuplexStream *s { ILibDuktape_WebSocket_State *state = (ILibDuktape_WebSocket_State*)user; ILibDuktape_httpStream_webSocket_WriteWebSocketPacket(state, WEBSOCKET_OPCODE_CLOSE, NULL, 0, ILibWebClient_WebSocket_FragmentFlag_Complete); - - // - // We need to call 'end' on the encoded stream, so that it can disconnect - // - if (ILibMemory_CanaryOK(state) && ILibMemory_CanaryOK(state->ctx)) - { - duk_push_heapptr(state->ctx, state->ObjectPtr); // [websocket] - duk_get_prop_string(state->ctx, -1, "encoded"); // [websocket][encoded] - duk_prepare_method_call(state->ctx, -1, "end"); // [websocket][encoded][end][this] - duk_pcall_method(state->ctx, 0); duk_pop(state->ctx); // [websocket][encoded] - duk_pop_2(state->ctx); // ... - } } void ILibDuktape_httpStream_webSocket_DecodedPauseSink_Chain(void *chain, void *user) {