hwpfilter/qa/cppunit/data/pass/ofz44992-1.hwp |binary
 hwpfilter/source/hwpreader.cxx                |    3 ++-
 2 files changed, 2 insertions(+), 1 deletion(-)

New commits:
commit 7d2785e37fee0b55c3751d94336320495b0b408e
Author:     Caolán McNamara <caol...@redhat.com>
AuthorDate: Thu Feb 24 08:39:33 2022 +0000
Commit:     Caolán McNamara <caol...@redhat.com>
CommitDate: Thu Feb 24 11:59:29 2022 +0100

    ofz#44992 Null-dereference
    
    Change-Id: I8b0251644769b490da97e6b0f97a320279f926f2
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/130473
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caol...@redhat.com>

diff --git a/hwpfilter/qa/cppunit/data/pass/ofz44992-1.hwp 
b/hwpfilter/qa/cppunit/data/pass/ofz44992-1.hwp
new file mode 100644
index 000000000000..1b46c9751396
Binary files /dev/null and b/hwpfilter/qa/cppunit/data/pass/ofz44992-1.hwp 
differ
diff --git a/hwpfilter/source/hwpreader.cxx b/hwpfilter/source/hwpreader.cxx
index 923d81f32cc8..40bd3186c288 100644
--- a/hwpfilter/source/hwpreader.cxx
+++ b/hwpfilter/source/hwpreader.cxx
@@ -1451,7 +1451,8 @@ void HwpReader::makePStyle(ParaShape const * pshape)
     rstartEl("style:style", mxList);
     mxList->clear();
     parseParaShape(pshape);
-    parseCharShape(pshape->cshape.get());
+    if (pshape->cshape)
+        parseCharShape(pshape->cshape.get());
     rstartEl("style:properties", mxList);
     mxList->clear();
 

Reply via email to