poi-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From n...@apache.org
Subject svn commit: r1243907 - in /poi/trunk/src: documentation/content/xdocs/status.xml scratchpad/src/org/apache/poi/hwpf/usermodel/CharacterRun.java
Date Tue, 14 Feb 2012 12:56:30 GMT
Author: nick
Date: Tue Feb 14 12:56:30 2012
New Revision: 1243907

URL: http://svn.apache.org/viewvc?rev=1243907&view=rev
Log:
Apply patch from bug #52662 - CharacterRun NPE fix when fetching symbol fonts, where no fonts
are defined

Modified:
    poi/trunk/src/documentation/content/xdocs/status.xml
    poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/usermodel/CharacterRun.java

Modified: poi/trunk/src/documentation/content/xdocs/status.xml
URL: http://svn.apache.org/viewvc/poi/trunk/src/documentation/content/xdocs/status.xml?rev=1243907&r1=1243906&r2=1243907&view=diff
==============================================================================
--- poi/trunk/src/documentation/content/xdocs/status.xml (original)
+++ poi/trunk/src/documentation/content/xdocs/status.xml Tue Feb 14 12:56:30 2012
@@ -34,6 +34,7 @@
 
     <changes>
         <release version="3.8-beta6" date="2012-??-??">
+           <action dev="poi-developers" type="fix">52662 - CharacterRun NPE fix when
fetching symbol fonts, where no fonts are defined</action>
            <action dev="poi-developers" type="add">52658 - support mergin table cells
in XSLF</action>
            <action dev="poi-developers" type="add">validate row number and column index
in SXSSF when creating new rows / cells</action>
            <action dev="poi-developers" type="fix">51498 - fixed evaluation of blank
cells in COUNTIF</action>

Modified: poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/usermodel/CharacterRun.java
URL: http://svn.apache.org/viewvc/poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/usermodel/CharacterRun.java?rev=1243907&r1=1243906&r2=1243907&view=diff
==============================================================================
--- poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/usermodel/CharacterRun.java (original)
+++ poi/trunk/src/scratchpad/src/org/apache/poi/hwpf/usermodel/CharacterRun.java Tue Feb 14
12:56:30 2012
@@ -606,8 +606,13 @@ public final class CharacterRun
   public Ffn getSymbolFont()
   {
     if (isSymbol()) {
+      if (_doc.getFontTable() == null)
+        return null;
+      
+      // Fetch all font names
       Ffn[] fontNames = _doc.getFontTable().getFontNames();
 
+      // Try to find the name of the font for our symbol
       if (fontNames.length <= _props.getFtcSym())
         return null;
 



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


Mime
View raw message