summaryrefslogtreecommitdiff
path: root/cppuhelper
diff options
context:
space:
mode:
authorNoel Grandin <noel.grandin@collabora.co.uk>2017-05-26 10:58:42 +0200
committerNoel Grandin <noel.grandin@collabora.co.uk>2017-05-28 19:44:08 +0200
commitef513fd4b049b214a03fbe6e62a5ea43680a7a9b (patch)
tree82f2ce93bc8e5fde6dce8685b633c3d643c9f069 /cppuhelper
parent826f1bca40a01f0a249d5b6cbb7c39c11638a060 (diff)
remove unnecessary use of OString::getStr
Change-Id: I0490efedf459190521f4339854b3394d57765fdb Reviewed-on: https://gerrit.libreoffice.org/38058 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'cppuhelper')
-rw-r--r--cppuhelper/source/component.cxx6
-rw-r--r--cppuhelper/source/component_context.cxx3
-rw-r--r--cppuhelper/source/implbase.cxx12
-rw-r--r--cppuhelper/source/weak.cxx6
4 files changed, 8 insertions, 19 deletions
diff --git a/cppuhelper/source/component.cxx b/cppuhelper/source/component.cxx
index fdff1a21bab8..333812495fa6 100644
--- a/cppuhelper/source/component.cxx
+++ b/cppuhelper/source/component.cxx
@@ -92,12 +92,8 @@ void OComponentHelper::release() throw()
catch (css::uno::RuntimeException & exc)
{
// release should not throw exceptions
-#if OSL_DEBUG_LEVEL > 0
- OString msg( OUStringToOString( exc.Message, RTL_TEXTENCODING_ASCII_US ) );
- OSL_FAIL( msg.getStr() );
-#else
(void) exc; // avoid warning about unused variable
-#endif
+ SAL_WARN( "cppuhelper", exc.Message );
}
// only the alive ref holds the object
diff --git a/cppuhelper/source/component_context.cxx b/cppuhelper/source/component_context.cxx
index 2df1b495689c..ee964e227c57 100644
--- a/cppuhelper/source/component_context.cxx
+++ b/cppuhelper/source/component_context.cxx
@@ -574,8 +574,7 @@ extern "C" { static void s_createComponentContext_v(va_list * pParam)
catch (Exception & exc)
{
(void) exc; // avoid warning about unused variable
- OSL_FAIL( OUStringToOString(
- exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
+ SAL_WARN( "cppuhelper", exc.Message );
xContext.clear();
}
}
diff --git a/cppuhelper/source/implbase.cxx b/cppuhelper/source/implbase.cxx
index 6118ccb79fc1..c8b72f61a48f 100644
--- a/cppuhelper/source/implbase.cxx
+++ b/cppuhelper/source/implbase.cxx
@@ -77,10 +77,8 @@ void WeakComponentImplHelperBase::release()
dispose();
}
catch (RuntimeException const& exc) { // don't break throw ()
- OSL_FAIL(
- OUStringToOString(
- exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
- static_cast<void>(exc);
+ (void)exc;
+ SAL_WARN( "cppuhelper", exc.Message );
}
OSL_ASSERT( rBHelper.bDisposed );
}
@@ -204,10 +202,8 @@ void WeakAggComponentImplHelperBase::release()
dispose();
}
catch (RuntimeException const& exc) { // don't break throw ()
- OSL_FAIL(
- OUStringToOString(
- exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
- static_cast<void>(exc);
+ (void)exc;
+ SAL_WARN( "cppuhelper", exc.Message );
}
OSL_ASSERT( rBHelper.bDisposed );
}
diff --git a/cppuhelper/source/weak.cxx b/cppuhelper/source/weak.cxx
index b52634b26ecc..6bd49fa212ec 100644
--- a/cppuhelper/source/weak.cxx
+++ b/cppuhelper/source/weak.cxx
@@ -243,10 +243,8 @@ void OWeakObject::disposeWeakConnectionPoint()
p->dispose();
}
catch (RuntimeException const& exc) {
- OSL_FAIL(
- OUStringToOString(
- exc.Message, RTL_TEXTENCODING_ASCII_US ).getStr() );
- static_cast<void>(exc);
+ (void)exc;
+ SAL_WARN( "cppuhelper", exc.Message );
}
p->release();
}