# HG changeset patch # User Sebastien Jodogne # Date 1418038970 -3600 # Node ID aea9277dee75d6baf82b763afc0e3119ac16a475 # Parent a0e420c5f2b88ece0d91e2ce35996a2a1096eebf catch more exceptions (patch from Valdas Rapsevicius) diff -r a0e420c5f2b8 -r aea9277dee75 OrthancServer/main.cpp --- a/OrthancServer/main.cpp Mon Dec 08 12:31:35 2014 +0100 +++ b/OrthancServer/main.cpp Mon Dec 08 12:42:50 2014 +0100 @@ -695,11 +695,21 @@ } } } - catch (OrthancException& e) + catch (const OrthancException& e) { LOG(ERROR) << "Uncaught exception, stopping now: [" << e.What() << "]"; status = -1; } + catch (const std::exception& e) + { + LOG(ERROR) << "Uncaught exception, stopping now: [" << e.what() << "]"; + status = -1; + } + catch (const std::string& s) + { + LOG(ERROR) << "Uncaught exception, stopping now: [" << s << "]"; + status = -1; + } catch (...) { LOG(ERROR) << "Native exception, stopping now. Check your plugins, if any.";