From 27ecd5c940b420b91da7450b66468cee51fa1eb0 Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Fri, 24 Jun 2022 13:48:11 +0800 Subject: [PATCH] =?UTF-8?q?websocket=20=E6=B7=BB=E5=8A=A0ping=E6=B6=88?= =?UTF-8?q?=E6=81=AF=E5=A4=84=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- a8/websocketsession.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/a8/websocketsession.cc b/a8/websocketsession.cc index dcf2dd4..0bd4eb8 100644 --- a/a8/websocketsession.cc +++ b/a8/websocketsession.cc @@ -212,8 +212,10 @@ namespace a8 return; } if (opcode != BINARY_MODE) { - Close(); - return; + if (opcode != WEBSOCKET_FRAME_PING) { + Close(); + return; + } } if (!is_final_frame) { Close();