Author: maxberger
Date: Tue Sep 15 14:02:48 2009
New Revision: 815330

URL: http://svn.apache.org/viewvc?rev=815330&view=rev
Log:
removed possible null reference

Modified:
    
xmlgraphics/fop/trunk/src/java/org/apache/fop/render/pdf/AbstractImageAdapter.java

Modified: 
xmlgraphics/fop/trunk/src/java/org/apache/fop/render/pdf/AbstractImageAdapter.java
URL: 
http://svn.apache.org/viewvc/xmlgraphics/fop/trunk/src/java/org/apache/fop/render/pdf/AbstractImageAdapter.java?rev=815330&r1=815329&r2=815330&view=diff
==============================================================================
--- 
xmlgraphics/fop/trunk/src/java/org/apache/fop/render/pdf/AbstractImageAdapter.java
 (original)
+++ 
xmlgraphics/fop/trunk/src/java/org/apache/fop/render/pdf/AbstractImageAdapter.java
 Tue Sep 15 14:02:48 2009
@@ -129,12 +129,12 @@
             if (cs == null && desc.startsWith("sRGB")) {
                 //It's the default sRGB profile which we mapped to DefaultRGB 
in PDFRenderer
                 cs = doc.getResources().getColorSpace("DefaultRGB");
-                if (cs == null) {
-                    //sRGB hasn't been set up for the PDF document
-                    //so install but don't set to DefaultRGB
-                    cs = PDFICCBasedColorSpace.setupsRGBColorSpace(doc);
-                }
             }
+            if (cs == null) {
+                // sRGB hasn't been set up for the PDF document
+                // so install but don't set to DefaultRGB
+                cs = PDFICCBasedColorSpace.setupsRGBColorSpace(doc);
+            }            
             pdfICCStream = cs.getICCStream();
         }
         return pdfICCStream;



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to