diff options
author | Julien Nabet <serval2412@yahoo.fr> | 2013-12-29 19:06:11 +0100 |
---|---|---|
committer | Julien Nabet <serval2412@yahoo.fr> | 2013-12-29 19:11:08 +0100 |
commit | ebe616de53b98e419c39782c6615877a12f0edc7 (patch) | |
tree | 9da9e8a6fa729b232cf6f443f2924911b04734aa /vcl | |
parent | 2cdde2a5fc94c1840fcd97122e48d84f0170c37c (diff) |
Resolves: fdo#72961 Crash when you open ODFver.1.0/1.1 created by LibO-3.5/3.6
It seems pAction may be NULL so let's keep on to check it.
Change-Id: Ie1a48c96bfa930364053c7c3ad0c940559544e33
Diffstat (limited to 'vcl')
-rw-r--r-- | vcl/source/gdi/gdimtf.cxx | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/vcl/source/gdi/gdimtf.cxx b/vcl/source/gdi/gdimtf.cxx index 1d89dea13de9..2e7417260c2f 100644 --- a/vcl/source/gdi/gdimtf.cxx +++ b/vcl/source/gdi/gdimtf.cxx @@ -2765,15 +2765,17 @@ SvStream& operator>>( SvStream& rIStm, GDIMetaFile& rGDIMetaFile ) { pAction = MetaAction::ReadMetaAction( rIStm, &aReadData ); - if (pAction->GetType() == META_COMMENT_ACTION) - { - MetaCommentAction* pCommentAct = static_cast<MetaCommentAction*>(pAction); - if ( pCommentAct->GetComment() == "EMF_PLUS" ) - rGDIMetaFile.UseCanvas( sal_True ); - } if( pAction ) + { + if (pAction->GetType() == META_COMMENT_ACTION) + { + MetaCommentAction* pCommentAct = static_cast<MetaCommentAction*>(pAction); + if ( pCommentAct->GetComment() == "EMF_PLUS" ) + rGDIMetaFile.UseCanvas( sal_True ); + } rGDIMetaFile.AddAction( pAction ); + } } } else |