summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--xmloff/source/core/xmlexp.cxx9
1 files changed, 7 insertions, 2 deletions
diff --git a/xmloff/source/core/xmlexp.cxx b/xmloff/source/core/xmlexp.cxx
index aced8d37b245..b1ca265b77b6 100644
--- a/xmloff/source/core/xmlexp.cxx
+++ b/xmloff/source/core/xmlexp.cxx
@@ -844,9 +844,14 @@ sal_Bool SAL_CALL SvXMLExport::filter( const uno::Sequence< beans::PropertyValue
// We must catch exceptions, because according to the
// API definition export must not throw one!
css::uno::Any ex(cppu::getCaughtException());
+ OUString sMessage( ex.getValueTypeName() + ": \"" + e.Message + "\"");
+ if (e.Context.is())
+ {
+ const char* pContext = typeid(*e.Context.get()).name();
+ sMessage += " (context: " + OUString::createFromAscii(pContext) + " )";
+ }
SetError( XMLERROR_FLAG_ERROR | XMLERROR_FLAG_SEVERE | XMLERROR_API,
- Sequence<OUString>(),
- ex.getValueTypeName() + ": \"" + e.Message + "\"", nullptr );
+ Sequence<OUString>(), sMessage, nullptr );
}
// return true only if no error occurred