We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6597564 commit 336f346Copy full SHA for 336f346
webserver/server.cpp
@@ -76,7 +76,8 @@ void server_base::run() {
76
77
/// Ask the server to stop using asynchronous command
78
void server_base::stop() {
79
- handle_stop();
+ // Post a call to the stop function so that server_base::stop() is safe to call from any thread.
80
+ io_service_.post(boost::bind(&server_base::handle_stop, this));
81
}
82
83
/// Returns true if the server is stopped.
0 commit comments