Don't use exceptions as part of normal flow (#872)

This commit is contained in:
Murat Seker
2020-07-19 14:44:59 +02:00
committed by GitHub
parent a8954f2cc0
commit c85b4c530c
3 changed files with 37 additions and 56 deletions

View File

@@ -93,11 +93,6 @@ void StaticFileServing::onRequestNeedsReply (QtHttpRequest * request, QtHttpRepl
{
_cgi.exec(uri_parts, request, reply);
}
catch(int err)
{
Error(_log,"Exception while executing cgi %s : %d", path.toStdString().c_str(), err);
printErrorToReply (reply, QtHttpReply::InternalError, "script failed (" % path % ")");
}
catch(std::exception &e)
{
Error(_log,"Exception while executing cgi %s : %s", path.toStdString().c_str(), e.what());