From d3484d57a8f630a690c5c635f3808cf737188233 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Thu, 8 Nov 2018 14:02:31 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0websocket=20close=E5=A4=84?= =?UTF-8?q?=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- a8/websocketsession.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/a8/websocketsession.cc b/a8/websocketsession.cc index f3b87fa..65bb4a6 100644 --- a/a8/websocketsession.cc +++ b/a8/websocketsession.cc @@ -174,6 +174,10 @@ namespace a8 bool opcode_is_control = opcode & 0x8; #endif + if (opcode == WEBSOCKET_FRAME_CLOSE) { + Close(); + return; + } if (!is_final_frame) { return; }