You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I try hello_world_server.cpp example. After I start the program and send the request, I've got the following problem.
terminate called after throwing an instance of 'boost::exception_detail::clone_impl<std::__exception_ptr::exception_ptr>'
I find the problem just in the following code.
struct hello_world {
/*<< This is the function that handles the incoming request. >>*/
void operator()(server::request const &request, server::connection_ptr response) {
server::string_type ip = source(request);
unsigned int port = request.source_port;
std::ostringstream data;
data << "Hello, " << ip << ':' << port << '!';
response->write(data.str()); // where the problem occurs !!!!!
}
};
Any solutions ? Many thanks !
The text was updated successfully, but these errors were encountered:
I try hello_world_server.cpp example. After I start the program and send the request, I've got the following problem.
I find the problem just in the following code.
Any solutions ? Many thanks !
The text was updated successfully, but these errors were encountered: