diff --git a/src/websocket.c b/src/websocket.c index 6a23972..3c12b44 100644 --- a/src/websocket.c +++ b/src/websocket.c @@ -287,12 +287,6 @@ int ws_send_frame(ws_connection_t* conn, uint8_t opcode, const uint8_t* payload, return -1; } - size_t max_frame_size = 10 + payload_len; - if (max_frame_size > 65536) - { - max_frame_size = 65536; - } - uint8_t buffer[65536]; // Limit payload to avoid overflow (65536 - 10 bytes for max header)