mirror of
https://github.com/smallmain/cocos-enhance-kit.git
synced 2025-10-09 11:05:24 +00:00
[engine] [cocos2d-x] [jsb-adapter] 适配引擎 v2.4.10 版本
This commit is contained in:
@@ -853,7 +853,10 @@ void WebSocketImpl::close()
|
||||
|
||||
void WebSocketImpl::closeAsync(int code, const std::string &reason)
|
||||
{
|
||||
lws_close_reason(_wsInstance, (lws_close_status)code, (unsigned char*)const_cast<char*>(reason.c_str()), reason.length());
|
||||
if (_wsInstance)
|
||||
{
|
||||
lws_close_reason(_wsInstance, (lws_close_status)code, (unsigned char*)const_cast<char*>(reason.c_str()), reason.length());
|
||||
}
|
||||
closeAsync();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user