diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2016-08-25 11:20:04 +0200 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2016-08-25 11:20:04 +0200 |
commit | 17e137d899de51f2cab485d4e339009954e558b5 (patch) | |
tree | 00509670b3c6a85da8c20fea06afaae217c367e2 /connectivity | |
parent | 4a95aa62ba34e1573540dc4395241e2654718c48 (diff) |
Improve exception construction
Change-Id: I2c1d28bb7c841f594fe2fdaf5f34fcdd730d8ee2
Diffstat (limited to 'connectivity')
-rw-r--r-- | connectivity/source/drivers/firebird/Connection.cxx | 8 |
1 files changed, 3 insertions, 5 deletions
diff --git a/connectivity/source/drivers/firebird/Connection.cxx b/connectivity/source/drivers/firebird/Connection.cxx index e18be5ad628a..ba2998f3e6cf 100644 --- a/connectivity/source/drivers/firebird/Connection.cxx +++ b/connectivity/source/drivers/firebird/Connection.cxx @@ -55,6 +55,7 @@ #include <comphelper/processfactory.hxx> #include <comphelper/storagehelper.hxx> +#include <cppuhelper/exc_hlp.hxx> #include <unotools/tempfile.hxx> #include <unotools/localfilehelper.hxx> #include <unotools/ucbstreamhelper.hxx> @@ -846,11 +847,8 @@ void SAL_CALL Connection::documentEventOccured( const DocumentEvent& Event ) } catch (const SQLException& e) { - WrappedTargetRuntimeException aExceptionWrapper; - aExceptionWrapper.Context = e.Context; - aExceptionWrapper.Message = e.Message; - aExceptionWrapper.TargetException <<= e; - throw WrappedTargetRuntimeException( aExceptionWrapper ); + auto a = cppu::getCaughtException(); + throw WrappedTargetRuntimeException(e.Message, e.Context, a); } |