pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From til...@apache.org
Subject svn commit: r1764943 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDICCBased.java
Date Fri, 14 Oct 2016 16:24:47 GMT
Author: tilman
Date: Fri Oct 14 16:24:47 2016
New Revision: 1764943

URL: http://svn.apache.org/viewvc?rev=1764943&view=rev
Log:
PDFBOX-3531: replace CMMException trigger with one that works for both KCMS and LittleCMS

Modified:
    pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDICCBased.java

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDICCBased.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDICCBased.java?rev=1764943&r1=1764942&r2=1764943&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDICCBased.java
(original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/pdmodel/graphics/color/PDICCBased.java
Fri Oct 14 16:24:47 2016
@@ -32,7 +32,6 @@ import org.apache.pdfbox.pdmodel.common.
 import org.apache.pdfbox.pdmodel.common.PDRange;
 import org.apache.pdfbox.pdmodel.common.PDStream;
 
-import java.awt.Color;
 import java.awt.color.CMMException;
 import java.awt.color.ICC_ColorSpace;
 import java.awt.color.ICC_Profile;
@@ -142,7 +141,7 @@ public final class PDICCBased extends PD
 
             // create a color in order to trigger a ProfileDataException
             // or CMMException due to invalid profiles, see PDFBOX-1295 and PDFBOX-1740
-            new Color(awtColorSpace, new float[getNumberOfComponents()], 1f);
+            awtColorSpace.fromRGB(new float[3]);
         }
         catch (RuntimeException e)
         {



Mime
View raw message