[OpenJDK 2D-Dev] Review request for bug 100053

Roman Kennke Roman.Kennke at Sun.COM
Thu Oct 1 21:13:26 UTC 2009

Hi Dmitri,

>    a comment about the test: would the bug reproduce if you just rendered into a 
> BufferedImage? If so, no need for creating a frame and such.

Oh yes. Stupid me :-)

>    Regarding the fix, it looks ok - but there are other places in the code where 
> the 'crossings' is accessed - are those safe from an NPE?

I followed all usages of crossings and crossingsIndices and they all end
up in endRendering(). There is a loop at the beginning of which the
arrays get initialized using setCrossingsExtends(). The problem occured
when this loop was never entered, in that case we hit
crossingListFinished() with (possibly) null arrays. There I added the
null checks and it should cover all potential NPEs on these arrays.

The updated webrev is:


Ok now?

Thanks, Roman

More information about the 2d-dev mailing list