pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1713481 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDCIDFont.java
Date Mon, 09 Nov 2015 17:12:36 GMT
Author: tilman
Date: Mon Nov  9 17:12:35 2015
New Revision: 1713481

URL: http://svn.apache.org/viewvc?rev=1713481&view=rev
Log:
PDFBOX-3095: take default if width is NaN

Modified:
    pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDCIDFont.java

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDCIDFont.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDCIDFont.java?rev=1713481&r1=1713480&r2=1713481&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDCIDFont.java (original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/font/PDCIDFont.java Mon Nov
 9 17:12:35 2015
@@ -351,7 +351,7 @@ public abstract class PDCIDFont implemen
             }
         }
         float average = totalWidths / characterCount;
-        if (average <= 0)
+        if (average <= 0 || Float.isNaN(average))
         {
             average = getDefaultWidth();
         }



Mime
View raw message