summaryrefslogtreecommitdiff
path: root/writerfilter
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2012-10-04 12:49:08 +0100
committerCaolán McNamara <caolanm@redhat.com>2012-10-04 12:49:28 +0100
commit0f3f9cb63056715845d9c3565bde69470c73efb2 (patch)
tree21f726cb00d4ec286a56ee3c7216fd2c0d21f12a /writerfilter
parentb243afd8755c2a470c6aa0607f5773bedd026937 (diff)
Related: rhbz#862467 band-aid when creating embedded object fails
Change-Id: Ie5ecc8f56636e692a6e17a2e8fab0cefd46cdfb4
Diffstat (limited to 'writerfilter')
-rw-r--r--writerfilter/source/ooxml/OOXMLFastContextHandler.cxx3
1 files changed, 3 insertions, 0 deletions
diff --git a/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx b/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
index 8670a45ffbb6..920bf31faa94 100644
--- a/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
+++ b/writerfilter/source/ooxml/OOXMLFastContextHandler.cxx
@@ -2474,6 +2474,9 @@ void OOXMLFastContextHandlerMath::process()
comphelper::EmbeddedObjectContainer container;
OUString aName;
uno::Reference< embed::XEmbeddedObject > ref = container.CreateEmbeddedObject( name.GetByteSequence(), aName );
+ assert(ref.is());
+ if (!ref.is())
+ return;
uno::Reference< uno::XInterface > component( ref->getComponent(), uno::UNO_QUERY );
// gcc4.4 (and 4.3 and possibly older) have a problem with dynamic_cast directly to the target class,
// so help it with an intermediate cast. I'm not sure what exactly the problem is, seems to be unrelated