Update the submodule trantor

This commit is contained in:
antao 2019-04-27 12:17:46 +08:00
parent 17ffbb6a0f
commit 0b96089a0a
2 changed files with 5 additions and 2 deletions

View File

@ -66,7 +66,11 @@ static void defaultConnectionCallback(const trantor::TcpConnectionPtr &conn)
HttpServer::HttpServer(EventLoop *loop,
const InetAddress &listenAddr,
const std::string &name)
#ifdef __linux__
: _server(loop, listenAddr, name.c_str()),
#else
: _server(loop, listenAddr, name.c_str(), true, false),
#endif
_httpAsyncCallback(defaultHttpAsyncCallback),
_newWebsocketCallback(defaultWebSockAsyncCallback),
_connectionCallback(defaultConnectionCallback)
@ -155,7 +159,6 @@ void HttpServer::onMessage(const TcpConnectionPtr &conn,
if (resp->statusCode() == k101SwitchingProtocols)
{
requestParser->setWebsockConnection(wsConn);
}
auto httpString = std::dynamic_pointer_cast<HttpResponseImpl>(resp)->renderToString();
conn->send(httpString);

@ -1 +1 @@
Subproject commit 4680663d3529d3cba41d688d15661306dd23c0d9
Subproject commit 26c2df7b005901dd9a2255374d67a81414a9c893