summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-08-12 12:06:49 +0100
committerMiklos Vajna <vmiklos@collabora.co.uk>2014-08-14 18:51:07 +0200
commit8f8fd00b8f67028c7f158e38d30e94819984a811 (patch)
tree93c0f07aadb1e65c785c386ab80b75dd492f4196
parentd4928dde73ca036e6337eb089faca3c8c2c93445 (diff)
Resolves: fdo#81046 don't crash on compilers that enforce exception specs
bit of a hammer here, the offending property is "IsSplitAllowed" if someone wants to attempt a more subtle fix (cherry picked from commit b59931d8a62f761022929f58f27d7ba22536b570) Change-Id: I37ed623a9947473fcb5c9e2b987d7a3dd9147ffa Signed-off-by: Miklos Vajna <vmiklos@collabora.co.uk>
-rw-r--r--sw/source/core/unocore/unotext.cxx18
1 files changed, 13 insertions, 5 deletions
diff --git a/sw/source/core/unocore/unotext.cxx b/sw/source/core/unocore/unotext.cxx
index f8867d972494..e066325812ea 100644
--- a/sw/source/core/unocore/unotext.cxx
+++ b/sw/source/core/unocore/unotext.cxx
@@ -2136,12 +2136,20 @@ lcl_ApplyCellProperties(
xCellCurs->gotoEnd( sal_True );
const uno::Reference< beans::XPropertyState >
xCellTextPropState(xCellCurs, uno::UNO_QUERY);
- const beans::PropertyState state = xCellTextPropState->getPropertyState(rName);
- if (state == beans::PropertyState_DEFAULT_VALUE)
+ try
{
- const uno::Reference< beans::XPropertySet >
- xCellTextProps(xCellCurs, uno::UNO_QUERY);
- xCellTextProps->setPropertyValue(rName, rValue);
+ const beans::PropertyState state = xCellTextPropState->getPropertyState(rName);
+ if (state == beans::PropertyState_DEFAULT_VALUE)
+ {
+ const uno::Reference< beans::XPropertySet >
+ xCellTextProps(xCellCurs, uno::UNO_QUERY);
+ xCellTextProps->setPropertyValue(rName, rValue);
+ }
+ }
+ catch (const uno::Exception& e)
+ {
+ SAL_WARN( "sw.uno", "Exception when getting PropertyState: "
+ + rName + ". Message: " + e.Message );
}
}
}