cli: Exit explicitly on unknown command

This commit is contained in:
Albert S. 2022-04-24 19:40:28 +02:00
parent a132485924
commit a8184191b3

View File

@ -106,12 +106,14 @@ int main(int argc, char *argv[])
} }
catch(const LooqsGeneralException &e) catch(const LooqsGeneralException &e)
{ {
Logger::error() << "Exception caught, message: " << e.message << Qt::endl; Logger::error() << "Exception caught, message:" << e.message << Qt::endl;
return 1;
} }
} }
else else
{ {
Logger::error() << "Unknown command " << commandName << Qt::endl; Logger::error() << "Unknown command:" << commandName << Qt::endl;
return 1;
} }
return app.exec(); return app.exec();