From dab623671c6bd8dc23c199abf005192a61ab4c27 Mon Sep 17 00:00:00 2001 From: William Pitcock Date: Sun, 3 Apr 2016 01:40:29 -0500 Subject: [PATCH] wsockd: set FIN attribute on all frames, we don't fragment --- wsockd/wsockd.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/wsockd/wsockd.c b/wsockd/wsockd.c index 59c42972..af38a574 100644 --- a/wsockd/wsockd.c +++ b/wsockd/wsockd.c @@ -390,6 +390,7 @@ conn_mod_write_short_frame(conn_t * conn, void *data, int len) ws_frame_hdr_t hdr; ws_frame_set_opcode(&hdr, WEBSOCKET_OPCODE_BINARY_FRAME); + ws_frame_set_fin(&hdr, 1); hdr.payload_length_mask = (len + 2) & 0x7f; conn_mod_write(conn, &hdr, sizeof(hdr)); @@ -403,6 +404,7 @@ conn_mod_write_long_frame(conn_t * conn, void *data, int len) ws_frame_ext_t hdr; ws_frame_set_opcode(&hdr.header, WEBSOCKET_OPCODE_BINARY_FRAME); + ws_frame_set_fin(&hdr.header, 1); hdr.header.payload_length_mask = 126; hdr.payload_length_extended = htons(len + 2);