summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2017-12-27 21:02:53 +0000
committerCaolán McNamara <caolanm@redhat.com>2017-12-28 21:04:47 +0100
commit996fbf1cefff1d991e4c89919797e5f0daeaafa9 (patch)
treed8a6c2ddd776b8400856b44b2e12f374a19b8256
parentc91281c9507e07330e1d7b04ca0674dd459ed2f7 (diff)
ofz#4814 asserts and Null-dereference on broken shape
the attempt is made, but the shape isn't there, so m_bShapeSent wasn't set, so it will get called again and the markstacks are popped to many times. Lets set it when the effort is made. Change-Id: I58dfe11316112cca6ff69ea518ed0b4908f25d6c Reviewed-on: https://gerrit.libreoffice.org/47106 Tested-by: Jenkins <ci@libreoffice.org> Reviewed-by: Caolán McNamara <caolanm@redhat.com> Tested-by: Caolán McNamara <caolanm@redhat.com>
-rw-r--r--writerfilter/source/ooxml/OOXMLFastContextHandler.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx b/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
index 138954023f89..9379fa95f3b4 100644
--- a/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
+++ b/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
@@ -1662,12 +1662,12 @@ void OOXMLFastContextHandlerShape::sendShape( Token_t Element )
awt::Point aPosition = mpStream->getPositionOffset();
mrShapeContext->setPosition(aPosition);
uno::Reference<drawing::XShape> xShape(mrShapeContext->getShape());
+ m_bShapeSent = true;
if (xShape.is())
{
OOXMLValue::Pointer_t
pValue(new OOXMLShapeValue(xShape));
newProperty(NS_ooxml::LN_shape, pValue);
- m_bShapeSent = true;
bool bIsPicture = Element == ( NMSP_dmlPicture | XML_pic );