summaryrefslogtreecommitdiff
path: root/oox
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2022-12-11 16:30:33 +0000
committerCaolán McNamara <caolanm@redhat.com>2022-12-11 19:25:50 +0000
commit3d9e4c5995d582f4a15120e84adc36efa7b4a49e (patch)
tree39ed23dc5d7e2eddc733375fdf16ca354634ba0c /oox
parent4af3a2998dd36a940f741b335e8327da2a4dead9 (diff)
crashtesting: null deref seen with forum-mso-en4-763051.xlsx
Change-Id: I721ab5fc78efafac9bcb7594e881773863d867f6 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143943 Tested-by: Jenkins Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'oox')
-rw-r--r--oox/source/drawingml/chart/converterbase.cxx6
1 files changed, 6 insertions, 0 deletions
diff --git a/oox/source/drawingml/chart/converterbase.cxx b/oox/source/drawingml/chart/converterbase.cxx
index bf85b7c02360..d7130ec9795d 100644
--- a/oox/source/drawingml/chart/converterbase.cxx
+++ b/oox/source/drawingml/chart/converterbase.cxx
@@ -31,6 +31,7 @@
#include <com/sun/star/lang/XMultiServiceFactory.hpp>
#include <com/sun/star/uno/XComponentContext.hpp>
#include <osl/diagnose.h>
+#include <sal/log.hxx>
#include <basegfx/numeric/ftools.hxx>
#include <oox/core/xmlfilterbase.hxx>
#include <oox/helper/helper.hxx>
@@ -85,6 +86,11 @@ void TitleLayoutInfo::convertTitlePos( ConverterRoot const & rRoot, const Refere
{
// try to get the title shape
Reference< XShape > xTitleShape = mpGetShape( rxChart1Doc );
+ if (!xTitleShape)
+ {
+ SAL_WARN("oox", "failed to get a TitleShape");
+ return;
+ }
// get title rotation angle, needed for correction of position of top-left edge
double fAngle = 0.0;
PropertySet aTitleProp( mxTitle );