From 020745ee2efdf424ba8e911fd40f8dbbbead1960 Mon Sep 17 00:00:00 2001 From: James Chen Date: Mon, 15 Aug 2016 13:59:01 +0800 Subject: [PATCH] Disables 'permessage-deflate' extension for WebSocket temporarily. (#16366) Currently, we couldn't find out the exact reason. libwebsockets official said it's probably an issue of user code since 'libwebsockets' passed AutoBahn stressed Test. --- cocos/network/WebSocket.cpp | 10 +++++++++- 1 file changed, 9 insertions(+), 1 deletion(-) diff --git a/cocos/network/WebSocket.cpp b/cocos/network/WebSocket.cpp index c19c3c5032..88cdbb7e6d 100644 --- a/cocos/network/WebSocket.cpp +++ b/cocos/network/WebSocket.cpp @@ -595,7 +595,15 @@ void WebSocket::onSubThreadStarted() info.port = CONTEXT_PORT_NO_LISTEN; info.protocols = _wsProtocols; - info.extensions = exts; + + // FIXME: Disable 'permessage-deflate' extension temporarily because of issues: + // https://github.com/cocos2d/cocos2d-x/issues/16045, https://github.com/cocos2d/cocos2d-x/issues/15767 + // libwebsockets issue: https://github.com/warmcat/libwebsockets/issues/593 + // Currently, we couldn't find out the exact reason. + // libwebsockets official said it's probably an issue of user code + // since 'libwebsockets' passed AutoBahn stressed Test. + +// info.extensions = exts; info.gid = -1; info.uid = -1;