diff options
author | Caolán McNamara <caolanm@redhat.com> | 2022-12-11 16:30:33 +0000 |
---|---|---|
committer | Xisco Fauli <xiscofauli@libreoffice.org> | 2022-12-12 11:54:01 +0000 |
commit | d4799f2a8cc077c118ac0fdcab4b88c3bdbf9be0 (patch) | |
tree | 1dfcd0e02fb2dd800f4dc99e5ca3e74c782a52cb /oox | |
parent | e777e0860c7f5dfb7a5f71102a69636935a091ba (diff) |
crashtesting: null deref seen with forum-mso-en4-763051.xlsx
Change-Id: I721ab5fc78efafac9bcb7594e881773863d867f6
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/143931
Reviewed-by: Michael Stahl <michael.stahl@allotropia.de>
Tested-by: Jenkins
Diffstat (limited to 'oox')
-rw-r--r-- | oox/source/drawingml/chart/converterbase.cxx | 6 |
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 ); |