You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@pdfbox.apache.org by ti...@apache.org on 2019/12/07 05:48:22 UTC
svn commit: r1870952 -
/pdfbox/branches/issue45/pdfbox/src/main/java/org/apache/pdfbox/rendering/TilingPaintFactory.java
Author: tilman
Date: Sat Dec 7 05:48:21 2019
New Revision: 1870952
URL: http://svn.apache.org/viewvc?rev=1870952&view=rev
Log:
PDFBOX-4071: avoid NPE
Modified:
pdfbox/branches/issue45/pdfbox/src/main/java/org/apache/pdfbox/rendering/TilingPaintFactory.java
Modified: pdfbox/branches/issue45/pdfbox/src/main/java/org/apache/pdfbox/rendering/TilingPaintFactory.java
URL: http://svn.apache.org/viewvc/pdfbox/branches/issue45/pdfbox/src/main/java/org/apache/pdfbox/rendering/TilingPaintFactory.java?rev=1870952&r1=1870951&r2=1870952&view=diff
==============================================================================
--- pdfbox/branches/issue45/pdfbox/src/main/java/org/apache/pdfbox/rendering/TilingPaintFactory.java (original)
+++ pdfbox/branches/issue45/pdfbox/src/main/java/org/apache/pdfbox/rendering/TilingPaintFactory.java Sat Dec 7 05:48:21 2019
@@ -127,7 +127,8 @@ class TilingPaintFactory
}
try
{
- if (this.color != other.color && this.color.toRGB() != other.color.toRGB())
+ if (this.color != null && other.color != null &&
+ this.color != other.color && this.color.toRGB() != other.color.toRGB())
{
return false;
}