Author: kiwiwings
Date: Wed Dec 30 23:33:05 2020
New Revision: 1884974

URL: http://svn.apache.org/viewvc?rev=1884974&view=rev
Log:
workaround NullPointerException when font family (of bullets) can't be 
determined

Added:
    poi/trunk/test-data/integration/stress022.pptx   (with props)
Modified:
    
poi/trunk/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTextParagraph.java

Modified: 
poi/trunk/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTextParagraph.java
URL: 
http://svn.apache.org/viewvc/poi/trunk/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTextParagraph.java?rev=1884974&r1=1884973&r2=1884974&view=diff
==============================================================================
--- 
poi/trunk/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTextParagraph.java 
(original)
+++ 
poi/trunk/src/ooxml/java/org/apache/poi/xslf/usermodel/XSLFTextParagraph.java 
Wed Dec 30 23:33:05 2020
@@ -858,7 +858,8 @@ public class XSLFTextParagraph implement
 
     @Override
     public String getDefaultFontFamily() {
-        return (_runs.isEmpty() ? "Arial" : _runs.get(0).getFontFamily());
+        String family = (_runs.isEmpty() ? null : 
_runs.get(0).getFontFamily());
+        return (family == null) ? "Arial" : family;
     }
 
     @Override

Added: poi/trunk/test-data/integration/stress022.pptx
URL: 
http://svn.apache.org/viewvc/poi/trunk/test-data/integration/stress022.pptx?rev=1884974&view=auto
==============================================================================
Binary file - no diff available.

Propchange: poi/trunk/test-data/integration/stress022.pptx
------------------------------------------------------------------------------
--- svn:mime-type (added)
+++ svn:mime-type Wed Dec 30 23:33:05 2020
@@ -0,0 +1 @@
+application/vnd.openxmlformats-officedocument.presentationml.presentation



---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@poi.apache.org
For additional commands, e-mail: commits-h...@poi.apache.org

Reply via email to