summaryrefslogtreecommitdiff
path: root/xmloff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-12-09 09:51:09 +0000
committerCaolán McNamara <caolanm@redhat.com>2014-12-09 09:51:32 +0000
commitbfd63516c9fd4ec366576f9a0e3c456bc3d530a3 (patch)
treef2668138206dd83ebbf2a359f3f591261da24a25 /xmloff
parentc0dcf49731c66b7169f668328ed4df73d1920b09 (diff)
Resolves: fdo#87108 crash on saving fodg
Change-Id: Ib88f0e9b0a3ba229c9e9f6cf20831c16051e3e29
Diffstat (limited to 'xmloff')
-rw-r--r--xmloff/source/draw/sdxmlexp.cxx11
1 files changed, 7 insertions, 4 deletions
diff --git a/xmloff/source/draw/sdxmlexp.cxx b/xmloff/source/draw/sdxmlexp.cxx
index 2988a4902074..03b785951d5e 100644
--- a/xmloff/source/draw/sdxmlexp.cxx
+++ b/xmloff/source/draw/sdxmlexp.cxx
@@ -2552,10 +2552,13 @@ void SdXMLExport::GetConfigurationSettings(uno::Sequence<beans::PropertyValue>&
Reference< beans::XPropertySet > xProps( xFac->createInstance("com.sun.star.document.Settings"), UNO_QUERY );
if( xProps.is() )
SvXMLUnitConverter::convertPropertySet( rProps, xProps );
- DocumentSettingsSerializer *pFilter;
- pFilter = dynamic_cast<DocumentSettingsSerializer *>(xProps.get());
- if( pFilter )
- rProps = pFilter->filterStreamsToStorage( GetTargetStorage(), rProps );
+ DocumentSettingsSerializer *pFilter(dynamic_cast<DocumentSettingsSerializer *>(xProps.get()));
+ if (!pFilter)
+ return;
+ const uno::Reference< embed::XStorage > xStorage(GetTargetStorage());
+ if (!xStorage.is())
+ return;
+ rProps = pFilter->filterStreamsToStorage(xStorage, rProps);
}
}