| Summary: | NPE in Attributes Tab of Web Page Editor Properties | ||||||
|---|---|---|---|---|---|---|---|
| Product: | [WebTools] Java Server Faces | Reporter: | Werner Keil <werner.keil> | ||||
| Component: | UI | Assignee: | Ian Trimble <ian.trimble> | ||||
| Status: | RESOLVED FIXED | QA Contact: | |||||
| Severity: | normal | ||||||
| Priority: | P2 | CC: | achima123, raghunathan.srinivasan, vrubezhny | ||||
| Version: | 3.3.1 | ||||||
| Target Milestone: | 3.4.0 M6 | ||||||
| Hardware: | PC | ||||||
| OS: | Windows XP | ||||||
| Whiteboard: | |||||||
| Attachments: |
|
||||||
|
Description
Werner Keil
I doubt ElementCMAdapter#getLength() should ever throw a NPE. (In reply to comment #1) > I doubt ElementCMAdapter#getLength() should ever throw a NPE. The reason of this NullPointerException is org.eclipse.jst.jsf.facelet.core.internal.cm.FaceletDocumentFactory.createExternalTagInfo(String) method returning null in case of JSFVersion cannot be calculated on a faceted project. But IMO this method should return new MetadataTagInfo(_project, uri) rather than just null. Created attachment 205355 [details]
The patch prevents NullPointerException in org.eclipse.jst.jsf.facelet.core.internal.cm.ElementCMAdapter.getLength() method call
The patch prevents NullPointerException in org.eclipse.jst.jsf.facelet.core.internal.cm.ElementCMAdapter.getLength() method call by returning TagInfo regardless of JSFVersion determination result.
In case of JSF Version couldn't be determined on faceted project it returns a new MetadataTagInfo object as TagInfo.
Thanks for the patch. We will review. Fix committed to HEAD at 2012/01/06 11:01AM PST. |