Commit c8e7db4b authored by Lukas Riedel's avatar Lukas Riedel

Change message pattern when terminating

Do not display the exception as 'error' message again
parent 020f554a
......@@ -262,22 +262,20 @@ int main(int argc, char** argv)
return 0;
}
catch (Dune::Exception &e){
catch (Dune::Exception &exc){
auto log = Dune::Dorie::create_base_logger();
log->error("DUNE reported error: {}", e.what());
log->critical("Aborting DORiE");
log->critical("Aborting DORiE after exception: {}", exc.what());
return 1;
}
catch (std::exception& e) {
catch (std::exception& exc) {
auto log = Dune::Dorie::create_base_logger();
log->error("Exception thrown: {}", e.what());
log->critical("Aborting DORiE");
log->critical("Aborting DORiE after exception: {}", exc.what());
return 1;
}
catch (...){
auto log = Dune::Dorie::create_base_logger();
log->error("Unknown error occurred");
log->critical("Aborting DORiE");
log->critical("Aborting DORiE after uncaught exception");
return 1;
}
}
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment