Kaydet (Commit) 07b3bfb1 authored tarafından Caolán McNamara's avatar Caolán McNamara

ofz#10395 Null-dereference

Change-Id: I7bde5987a51949d60174335327652186e0ad8998
Reviewed-on: https://gerrit.libreoffice.org/60559Reviewed-by: 's avatarCaolán McNamara <caolanm@redhat.com>
Tested-by: 's avatarCaolán McNamara <caolanm@redhat.com>
üst 487a05e8
......@@ -179,11 +179,14 @@ oox::core::ContextHandlerRef WpsContext::onCreateContext(sal_Int32 nElementToken
if (rAttribs.hasAttribute(XML_prst))
{
uno::Reference<beans::XPropertySet> xPropertySet(mxShape, uno::UNO_QUERY);
oox::OptValue<OUString> presetShapeName = rAttribs.getString(XML_prst);
const OUString& preset = presetShapeName.get();
comphelper::SequenceAsHashMap aCustomShapeGeometry(xPropertySet->getPropertyValue("CustomShapeGeometry"));
aCustomShapeGeometry["PresetTextWarp"] <<= preset;
xPropertySet->setPropertyValue("CustomShapeGeometry", uno::makeAny(aCustomShapeGeometry.getAsConstPropertyValueList()));
if (xPropertySet.is())
{
oox::OptValue<OUString> presetShapeName = rAttribs.getString(XML_prst);
const OUString& preset = presetShapeName.get();
comphelper::SequenceAsHashMap aCustomShapeGeometry(xPropertySet->getPropertyValue("CustomShapeGeometry"));
aCustomShapeGeometry["PresetTextWarp"] <<= preset;
xPropertySet->setPropertyValue("CustomShapeGeometry", uno::makeAny(aCustomShapeGeometry.getAsConstPropertyValueList()));
}
}
break;
case XML_txbx:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment