summaryrefslogtreecommitdiffstats
path: root/basic
diff options
context:
space:
mode:
author4k5h1t <ask160203@gmail.com>2021-09-10 22:48:40 +0530
committerMichael Stahl <michael.stahl@allotropia.de>2021-09-14 11:16:07 +0200
commit5f4a84ce5b775eb017bd784db95857684b7e90ed (patch)
tree982a43651462c17f36395e3c876043b42589baad /basic
parentsvx: GetMarkedObjectByIndex() may return nullptr (diff)
downloadcore-5f4a84ce5b775eb017bd784db95857684b7e90ed.tar.gz
core-5f4a84ce5b775eb017bd784db95857684b7e90ed.zip
tdf#42982: improve UNO API error reporting
Change-Id: I1252c89f23e70eb88744585bb2abd4fe3794e1d5 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/121918 Tested-by: Jenkins Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Diffstat (limited to 'basic')
-rw-r--r--basic/source/uno/dlgcont.cxx8
1 files changed, 4 insertions, 4 deletions
diff --git a/basic/source/uno/dlgcont.cxx b/basic/source/uno/dlgcont.cxx
index 5a125444dfc9..56305e820870 100644
--- a/basic/source/uno/dlgcont.cxx
+++ b/basic/source/uno/dlgcont.cxx
@@ -373,12 +373,12 @@ Reference< css::resource::XStringResourcePersistence >
xLibrariesStor = mxStorage->openStorageElement( maLibrariesDir, embed::ElementModes::READ );
// TODO: Should be READWRITE with new storage concept using store() instead of storeTo()
if ( !xLibrariesStor.is() )
- throw uno::RuntimeException("null returned from openStorageElement");
+ throw uno::RuntimeException("null returned from openStorageElement",static_cast< cppu::OWeakObject * >(this));
xLibraryStor = xLibrariesStor->openStorageElement( aLibName, embed::ElementModes::READ );
// TODO: Should be READWRITE with new storage concept using store() instead of storeTo()
if ( !xLibraryStor.is() )
- throw uno::RuntimeException("null returned from openStorageElement");
+ throw uno::RuntimeException("null returned from openStorageElement",static_cast< cppu::OWeakObject * >(this));
}
catch(const uno::Exception& )
{
@@ -426,12 +426,12 @@ void SfxDialogLibraryContainer::onNewRootStorage()
try {
xLibrariesStor = mxStorage->openStorageElement( maLibrariesDir, embed::ElementModes::READWRITE );
if ( !xLibrariesStor.is() )
- throw uno::RuntimeException("null returned from openStorageElement");
+ throw uno::RuntimeException("null returned from openStorageElement",static_cast< cppu::OWeakObject * >(this));
OUString aLibName = pDialogLibrary->getName();
xLibraryStor = xLibrariesStor->openStorageElement( aLibName, embed::ElementModes::READWRITE );
if ( !xLibraryStor.is() )
- throw uno::RuntimeException("null returned from openStorageElement");
+ throw uno::RuntimeException("null returned from openStorageElement",static_cast< cppu::OWeakObject * >(this));
Reference< resource::XStringResourceWithStorage >
xStringResourceWithStorage( xStringResourcePersistence, UNO_QUERY );