JDK-8128239 : Texture allocation should return null to caller rather than trying to use texture and getting NPE
  • Type: Bug
  • Component: javafx
  • Sub-Component: graphics
  • Affected Version: fx2.0
  • Priority: P4
  • Status: Closed
  • Resolution: Fixed
  • Submitted: 2011-09-02
  • Updated: 2015-06-17
  • Resolved: 2011-10-12
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
Other
fx2.0.2Fixed
Related Reports
Duplicate :  
Relates :  
Relates :  
Description
If you look at the stack trace from RT-16536 you will note that the Prism texture allocation methods try to access the return value of the allocated texture without checking for null, leading to an NPE. It would be easier for clients to do error handling if we returned the null without throwing NPE.

As a workaround, the client (the WebView renderer in this case) can catch the NPE.

Comments
The change set looks good to me and the issue was verified by dev.
16-11-2011

changeset: 14637:f031cc098c5b summary: fix : RT-16644 NPE on texture allocation
12-10-2011