X-Git-Url: http://git.tdb.fi/?p=libs%2Fcore.git;a=blobdiff_plain;f=source%2Fcore%2Fapplication.cpp;h=a49802350f2f7d655125d8ab0480d9e41370c72a;hp=0ef3443e8eac4fab7173b15df42c9cd1360b4e88;hb=0fa00d18f607f329d2b2a979e1d4339e233817fa;hpb=015d9ccbae576049e392b4dbc3017e00d8df3c49 diff --git a/source/core/application.cpp b/source/core/application.cpp index 0ef3443..a498023 100644 --- a/source/core/application.cpp +++ b/source/core/application.cpp @@ -6,6 +6,7 @@ Distributed under the LGPL */ #include #include +#include "../debug/demangle.h" #include "../time/units.h" #include "../time/utils.h" #include "application.h" @@ -40,16 +41,16 @@ int Application::run(int argc, char **argv) try { - app_=reg_app_->create_app(argc, argv); - } - catch(const UsageError &e) - { - reg_app_->usage(e.what(), argv[0], e.get_brief()); - return 1; - } + try + { + app_=reg_app_->create_app(argc, argv); + } + catch(const UsageError &e) + { + reg_app_->usage(e.what(), argv[0], e.get_brief()); + return 1; + } - try - { int result=app_->main(); delete app_; return result; @@ -57,10 +58,10 @@ int Application::run(int argc, char **argv) catch(const exception &e) { cerr<<"An uncaught exception occurred.\n"; - cerr<<" type: "<