diff options
author | Andrzej Rybczak <electricityispower@gmail.com> | 2014-08-31 08:46:57 +0200 |
---|---|---|
committer | Andrzej Rybczak <electricityispower@gmail.com> | 2014-08-31 08:47:27 +0200 |
commit | 5d6d390f77e10728b0288147567c19f1e1af8de7 (patch) | |
tree | dd229cfdae4c1c663bf6927d02e7e28c44c9c3e5 /src/ncmpcpp.cpp | |
parent | 4ac46f8c9db33a59517ea9d61ef63fafd35cd8d7 (diff) |
catch all exceptions and show them as unexpected errors
Diffstat (limited to 'src/ncmpcpp.cpp')
-rw-r--r-- | src/ncmpcpp.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/ncmpcpp.cpp b/src/ncmpcpp.cpp index 7faf3488..4b4edf3f 100644 --- a/src/ncmpcpp.cpp +++ b/src/ncmpcpp.cpp @@ -239,6 +239,10 @@ int main(int argc, char **argv) { Statusbar::printf("Error: %1%", e.errorMessage()); } + catch (std::exception &e) + { + Statusbar::printf("Unexpected error: %1%", e.what()); + } if (myScreen == myPlaylist) myPlaylist->EnableHighlighting(); |