summaryrefslogtreecommitdiff
path: root/stoc/source/corereflection/criface.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'stoc/source/corereflection/criface.cxx')
-rw-r--r--stoc/source/corereflection/criface.cxx33
1 files changed, 17 insertions, 16 deletions
diff --git a/stoc/source/corereflection/criface.cxx b/stoc/source/corereflection/criface.cxx
index c37108081fbe..041272a51a28 100644
--- a/stoc/source/corereflection/criface.cxx
+++ b/stoc/source/corereflection/criface.cxx
@@ -295,23 +295,24 @@ void IdlAttributeFieldImpl::set( const Any & rObj, const Any & rValue )
void IdlAttributeFieldImpl::checkException(
uno_Any * exception, Reference< XInterface > const & context) const
{
- if (exception != nullptr) {
- Any e;
- uno_any_destruct(&e, reinterpret_cast< uno_ReleaseFunc >(cpp_release));
- uno_type_any_constructAndConvert(
- &e, exception->pData, exception->pType,
- getReflection()->getUno2Cpp().get());
- uno_any_destruct(exception, nullptr);
- if (!e.isExtractableTo(
- cppu::UnoType<RuntimeException>::get()))
- {
- throw WrappedTargetRuntimeException(
- "non-RuntimeException occurred when accessing an"
- " interface type attribute",
- context, e);
- }
- cppu::throwException(e);
+ if (exception == nullptr)
+ return;
+
+ Any e;
+ uno_any_destruct(&e, reinterpret_cast< uno_ReleaseFunc >(cpp_release));
+ uno_type_any_constructAndConvert(
+ &e, exception->pData, exception->pType,
+ getReflection()->getUno2Cpp().get());
+ uno_any_destruct(exception, nullptr);
+ if (!e.isExtractableTo(
+ cppu::UnoType<RuntimeException>::get()))
+ {
+ throw WrappedTargetRuntimeException(
+ "non-RuntimeException occurred when accessing an"
+ " interface type attribute",
+ context, e);
}
+ cppu::throwException(e);
}