This commit is contained in:
Ivan Lezhankin 2021-03-04 17:01:37 +03:00
parent 91ff08452e
commit 6a07ee1506
2 changed files with 6 additions and 6 deletions

View File

@ -19,7 +19,7 @@ public:
explicit HTTPServer(
const Context & context,
HTTPRequestHandlerFactoryPtr factory,
UInt16 portNumber = 80,
UInt16 port_number = 80,
Poco::Net::HTTPServerParams::Ptr params = new Poco::Net::HTTPServerParams);
HTTPServer(
@ -31,13 +31,13 @@ public:
HTTPServer(
const Context & context,
HTTPRequestHandlerFactoryPtr factory,
Poco::ThreadPool & threadPool,
Poco::ThreadPool & thread_pool,
const Poco::Net::ServerSocket & socket,
Poco::Net::HTTPServerParams::Ptr params);
~HTTPServer() override;
void stopAll(bool abortCurrent = false);
void stopAll(bool abort_current = false);
private:
HTTPRequestHandlerFactoryPtr factory;

View File

@ -67,15 +67,15 @@ void HTTPServerConnection::run()
}
}
}
catch (Poco::Net::NoMessageException &)
catch (const Poco::Net::NoMessageException &)
{
break;
}
catch (Poco::Net::MessageException &)
catch (const Poco::Net::MessageException &)
{
sendErrorResponse(session, Poco::Net::HTTPResponse::HTTP_BAD_REQUEST);
}
catch (Poco::Exception &)
catch (const Poco::Exception &)
{
if (session.networkException())
{