ixwebsocketserver::broadcast server to return a boolean to know whether the server could start/listen, and use that in ws
This commit is contained in:
10
ws/ws.cpp
10
ws/ws.cpp
@ -2768,8 +2768,14 @@ int main(int argc, char** argv)
|
||||
ix::WebSocketServer server(port, hostname);
|
||||
server.setTLSOptions(tlsOptions);
|
||||
server.makeBroadcastServer();
|
||||
server.listenAndStart();
|
||||
server.wait();
|
||||
if (!server.listenAndStart())
|
||||
{
|
||||
spdlog::error("Error while starting the server");
|
||||
}
|
||||
else
|
||||
{
|
||||
server.wait();
|
||||
}
|
||||
}
|
||||
else if (app.got_subcommand("send"))
|
||||
{
|
||||
|
Reference in New Issue
Block a user