Mercurial > hg > orthanc-stone
diff OrthancStone/Sources/Messages/IObservable.cpp @ 1858:be88206f8d78
display what() of C++ exceptions on error while processing a message
author | Sebastien Jodogne <s.jodogne@gmail.com> |
---|---|
date | Mon, 06 Sep 2021 22:17:32 +0200 |
parents | 9ac2a65d4172 |
children | 3889ae96d2e9 |
line wrap: on
line diff
--- a/OrthancStone/Sources/Messages/IObservable.cpp Tue Aug 31 17:25:16 2021 +0200 +++ b/OrthancStone/Sources/Messages/IObservable.cpp Mon Sep 06 22:17:32 2021 +0200 @@ -27,6 +27,7 @@ #include <Logging.h> #include <cassert> +#include <stdexcept> namespace OrthancStone { @@ -88,6 +89,10 @@ { LOG(ERROR) << "Exception on callable: " << e.What(); } + catch (std::exception& e) + { + LOG(ERROR) << "C++ exception on callable: " << e.what(); + } catch (...) { LOG(ERROR) << "Native exception on callable";