xmlgraphics-fop-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jerem...@apache.org
Subject svn commit: r642923 - /xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/type1/AFMFile.java
Date Mon, 31 Mar 2008 08:39:51 GMT
Author: jeremias
Date: Mon Mar 31 01:39:49 2008
New Revision: 642923

URL: http://svn.apache.org/viewvc?rev=642923&view=rev
Log:
Fixed possible NullPointerException in AFM kerning table build code.

Modified:
    xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/type1/AFMFile.java

Modified: xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/type1/AFMFile.java
URL: http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/type1/AFMFile.java?rev=642923&r1=642922&r2=642923&view=diff
==============================================================================
--- xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/type1/AFMFile.java (original)
+++ xmlgraphics/fop/trunk/src/java/org/apache/fop/fonts/type1/AFMFile.java Mon Mar 31 01:39:49
2008
@@ -413,7 +413,7 @@
             Map.Entry entryFrom = (Map.Entry)iterFrom.next();
             String name1 = (String)entryFrom.getKey();
             AFMCharMetrics chm1 = getChar(name1);
-            if (!chm1.hasCharCode()) {
+            if (chm1 == null || !chm1.hasCharCode()) {
                 continue;
             }
             Map container = null;
@@ -423,7 +423,7 @@
                 Map.Entry entryTo = (Map.Entry)iterTo.next();
                 String name2 = (String)entryTo.getKey();
                 AFMCharMetrics chm2 = getChar(name2);
-                if (!chm2.hasCharCode()) {
+                if (chm2 == null || !chm2.hasCharCode()) {
                     continue;
                 }
                 if (container == null) {



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


Mime
View raw message