[Libreoffice-commits] core.git: writerfilter/qa writerfilter/source

Miklos Vajna vmiklos at collabora.co.uk
Mon Feb 17 18:14:13 CET 2014


 writerfilter/qa/cppunittests/rtftok/data/pass/abi3623.rtf |    7 +++++++
 writerfilter/source/dmapper/DomainMapper.cxx              |    2 +-
 2 files changed, 8 insertions(+), 1 deletion(-)

New commits:
commit 08fb25ab7941c52d4eed0435a45a38b03aff588c
Author: Miklos Vajna <vmiklos at collabora.co.uk>
Date:   Mon Feb 17 17:50:57 2014 +0100

    abi#3623 RTF import: missing null pointer check
    
    Change-Id: I5861e5fec0d822f42dfeb994500a818a968e69fb

diff --git a/writerfilter/qa/cppunittests/rtftok/data/pass/abi3623.rtf b/writerfilter/qa/cppunittests/rtftok/data/pass/abi3623.rtf
new file mode 100644
index 0000000..a47161a
--- /dev/null
+++ b/writerfilter/qa/cppunittests/rtftok/data/pass/abi3623.rtf
@@ -0,0 +1,7 @@
+{\rtf1
+{\stylesheet
+{\s2\ls1\sbasedon0 heading 2;}
+}
+\s2
+foo\par
+}
diff --git a/writerfilter/source/dmapper/DomainMapper.cxx b/writerfilter/source/dmapper/DomainMapper.cxx
index b3932c3..904cd40 100644
--- a/writerfilter/source/dmapper/DomainMapper.cxx
+++ b/writerfilter/source/dmapper/DomainMapper.cxx
@@ -2015,7 +2015,7 @@ void DomainMapper::sprmWithProps( Sprm& rSprm, PropertyMapPtr rContext, SprmType
                 {
                     const StyleSheetEntryPtr pParent = pStyleTable->FindStyleSheetByISTD(pEntry->sBaseStyleIdentifier);
                     const StyleSheetPropertyMap* pParentProperties = dynamic_cast<const StyleSheetPropertyMap*>(pParent ? pParent->pProperties.get() : 0);
-                    if (pParentProperties->find(PROP_PARA_RIGHT_MARGIN) != pParentProperties->end())
+                    if (pParentProperties && pParentProperties->find(PROP_PARA_RIGHT_MARGIN) != pParentProperties->end())
                         nParaRightMargin = pParentProperties->find(PROP_PARA_RIGHT_MARGIN)->second.getValue().get<sal_Int32>();
                 }
                 if (nParaRightMargin != 0)


More information about the Libreoffice-commits mailing list