diff options
author | Bayram Çiçek <mail@bayramcicek.com.tr> | 2021-01-10 21:47:43 +0000 |
---|---|---|
committer | Michael Stahl <michael.stahl@allotropia.de> | 2021-01-12 19:24:51 +0100 |
commit | 32676270d194b68d7dd811511feb0903876b5c06 (patch) | |
tree | bca2290ed287c583e3390e71d39c5b73df584969 | |
parent | 694f4e560c8a710e69268845575bbecfb5e23f76 (diff) |
tdf#42982: Improve UNO API error reporting
Change-Id: I78c6fed4e94f1ebfc772db4dec9955da7230bc3f
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/109071
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Tested-by: Jenkins
-rw-r--r-- | embeddedobj/source/msole/olepersist.cxx | 2 | ||||
-rw-r--r-- | package/source/xstor/owriteablestream.cxx | 2 | ||||
-rw-r--r-- | sfx2/source/doc/doctemplateslocal.cxx | 2 | ||||
-rw-r--r-- | svl/source/fsstor/fsfactory.cxx | 2 | ||||
-rw-r--r-- | xmloff/source/meta/xmlversion.cxx | 2 |
5 files changed, 5 insertions, 5 deletions
diff --git a/embeddedobj/source/msole/olepersist.cxx b/embeddedobj/source/msole/olepersist.cxx index 2d5dfbf59a4d..04d5b6433c07 100644 --- a/embeddedobj/source/msole/olepersist.cxx +++ b/embeddedobj/source/msole/olepersist.cxx @@ -102,7 +102,7 @@ OUString GetNewTempFileURL_Impl( const uno::Reference< uno::XComponentContext >& } if ( aResult.isEmpty() ) - throw uno::RuntimeException(); // TODO: can not create tempfile + throw uno::RuntimeException("Cannot create tempfile."); return aResult; } diff --git a/package/source/xstor/owriteablestream.cxx b/package/source/xstor/owriteablestream.cxx index 9655240c4602..77a34c533653 100644 --- a/package/source/xstor/owriteablestream.cxx +++ b/package/source/xstor/owriteablestream.cxx @@ -237,7 +237,7 @@ OUString GetNewTempFileURL( const uno::Reference< uno::XComponentContext >& rCon } if ( aTempURL.isEmpty() ) - throw uno::RuntimeException(); // TODO: can not create tempfile + throw uno::RuntimeException("Cannot create tempfile."); return aTempURL; } diff --git a/sfx2/source/doc/doctemplateslocal.cxx b/sfx2/source/doc/doctemplateslocal.cxx index d7c24934f89a..e72b74eb8efe 100644 --- a/sfx2/source/doc/doctemplateslocal.cxx +++ b/sfx2/source/doc/doctemplateslocal.cxx @@ -122,7 +122,7 @@ DocTemplLocaleHelper::~DocTemplLocaleHelper() std::vector< beans::StringPair > const & DocTemplLocaleHelper::GetParsingResult() const { if ( !m_aElementsSeq.empty() ) - throw uno::RuntimeException(); // the parsing has still not finished! + throw uno::RuntimeException("The parsing has still not finished!"); return m_aResultSeq; } diff --git a/svl/source/fsstor/fsfactory.cxx b/svl/source/fsstor/fsfactory.cxx index 91fe8d35f983..455e1b6ce590 100644 --- a/svl/source/fsstor/fsfactory.cxx +++ b/svl/source/fsstor/fsfactory.cxx @@ -40,7 +40,7 @@ uno::Reference< uno::XInterface > SAL_CALL FSStorageFactory::createInstance() OUString aTempURL = ::utl::TempFile( nullptr, true ).GetURL(); if ( aTempURL.isEmpty() ) - throw uno::RuntimeException(); // TODO: can not create tempfile + throw uno::RuntimeException("Cannot create tempfile."); ::ucbhelper::Content aResultContent( aTempURL, uno::Reference< ucb::XCommandEnvironment >(), diff --git a/xmloff/source/meta/xmlversion.cxx b/xmloff/source/meta/xmlversion.cxx index 7776ea876427..1276e0e6fcdf 100644 --- a/xmloff/source/meta/xmlversion.cxx +++ b/xmloff/source/meta/xmlversion.cxx @@ -325,7 +325,7 @@ void SAL_CALL XMLVersionListPersistence::store( const uno::Reference< embed::XSt Reference< io::XOutputStream > xOut = xVerStream->getOutputStream(); if ( !xOut.is() ) - throw uno::RuntimeException(); // the stream was successfully opened for writing already + throw uno::RuntimeException("The stream was successfully opened for writing already!"); xWriter->setOutputStream(xOut); |