From d2bb1c10a754c2503da980fdbdda47e387d70c72 Mon Sep 17 00:00:00 2001 From: antao Date: Fri, 5 Apr 2019 11:36:04 +0800 Subject: [PATCH] Fix a websocket issue in Linux --- lib/src/HttpAppFrameworkImpl.cc | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/src/HttpAppFrameworkImpl.cc b/lib/src/HttpAppFrameworkImpl.cc index b04c74de..38bb5397 100755 --- a/lib/src/HttpAppFrameworkImpl.cc +++ b/lib/src/HttpAppFrameworkImpl.cc @@ -318,6 +318,9 @@ void HttpAppFrameworkImpl::run() #endif } serverPtr->setHttpAsyncCallback(std::bind(&HttpAppFrameworkImpl::onAsyncRequest, this, _1, _2)); + serverPtr->setNewWebsocketCallback(std::bind(&HttpAppFrameworkImpl::onNewWebsockRequest, this, _1, _2, _3)); + serverPtr->setWebsocketMessageCallback(std::bind(&HttpAppFrameworkImpl::onWebsockMessage, this, _1, _2)); + serverPtr->setDisconnectWebsocketCallback(std::bind(&HttpAppFrameworkImpl::onWebsockDisconnect, this, _1)); serverPtr->setConnectionCallback(std::bind(&HttpAppFrameworkImpl::onConnection, this, _1)); serverPtr->kickoffIdleConnections(_idleConnectionTimeout); serverPtr->start();