[Libreoffice-commits] .: oox/source

Muthu Subramanian sumuthu at kemper.freedesktop.org
Tue Jul 10 06:47:58 PDT 2012


 oox/source/ppt/slidefragmenthandler.cxx |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 752c83258899be8b3541e25933905393b9c38698
Author: Muthu Subramanian <sumuthu at suse.com>
Date:   Tue Jul 10 19:39:36 2012 +0530

    Crash fix.
    
    Though getTheme() is not supposed to be returning NULL.
    It seems like doing that sometimes.

diff --git a/oox/source/ppt/slidefragmenthandler.cxx b/oox/source/ppt/slidefragmenthandler.cxx
index 29954f6..1b34a1a 100644
--- a/oox/source/ppt/slidefragmenthandler.cxx
+++ b/oox/source/ppt/slidefragmenthandler.cxx
@@ -174,7 +174,9 @@ SlideFragmentHandler::~SlideFragmentHandler() throw()
 
     case PPT_TOKEN( bgRef ):            // a:CT_StyleMatrixReference
         {
-            const FillProperties *pFillProperties = mpSlidePersistPtr->getTheme()->getFillStyle( rAttribs.getInteger( XML_idx, -1 ) );
+            const FillProperties *pFillProperties = NULL;
+            if( mpSlidePersistPtr->getTheme() )
+                pFillProperties = mpSlidePersistPtr->getTheme()->getFillStyle( rAttribs.getInteger( XML_idx, -1 ) );
             FillPropertiesPtr pFillPropertiesPtr( pFillProperties ? new FillProperties( *pFillProperties ) : new FillProperties() );
             ContextHandlerRef ret = new ColorContext( *this, mpSlidePersistPtr->getBackgroundColor() );
             mpSlidePersistPtr->setBackgroundProperties( pFillPropertiesPtr );


More information about the Libreoffice-commits mailing list