[Libreoffice-commits] .: Branch 'libreoffice-3-4' - oox/source

Radek Doulík rodo at kemper.freedesktop.org
Thu Apr 14 07:34:55 PDT 2011


 oox/source/drawingml/shape.cxx |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

New commits:
commit 8e3f32d42487a7c8dd4a8db6e998182ef7f14ef4
Author: Radek Doulik <rodo at novell.com>
Date:   Thu Apr 14 15:19:53 2011 +0200

    fix crash in fdo#36203, the referenced shape didn't contain texbody

diff --git a/oox/source/drawingml/shape.cxx b/oox/source/drawingml/shape.cxx
index 39bcd7b..1864125 100644
--- a/oox/source/drawingml/shape.cxx
+++ b/oox/source/drawingml/shape.cxx
@@ -198,7 +198,7 @@ void Shape::addShape(
 
 void Shape::applyShapeReference( const Shape& rReferencedShape )
 {
-    mpTextBody = TextBodyPtr( new TextBody( *rReferencedShape.mpTextBody.get() ) );
+    mpTextBody = TextBodyPtr( rReferencedShape.mpTextBody.get() ? new TextBody( *rReferencedShape.mpTextBody.get() ) : new TextBody() );
     maShapeProperties = rReferencedShape.maShapeProperties;
     mpLinePropertiesPtr = LinePropertiesPtr( new LineProperties( *rReferencedShape.mpLinePropertiesPtr.get() ) );
     mpFillPropertiesPtr = FillPropertiesPtr( new FillProperties( *rReferencedShape.mpFillPropertiesPtr.get() ) );


More information about the Libreoffice-commits mailing list