Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 318465

Summary: NullPointerException when using an XMLTransformationMapping
Product: z_Archived Reporter: Matt MacIvor <matt.macivor>
Component: EclipselinkAssignee: Nobody - feel free to take it <nobody>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3    
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
Proposed Fix and Test Case none

Description Matt MacIvor CLA 2010-06-30 09:23:13 EDT
In the case that EclipseLink is unmarshalling an xml document, and that document declares a prefix which goes out of scope prior to initializing the UnmarshalRecord's TransformationRecord, a NPE will occur.

This is because the list of prefixes returned from the UnmarshalNamespaceResolver still contains the out of scope prefix, but getNamespace returns null for that prefix. XMLTransformationRecord doesn't guard against the possibility of a null namespace uri being returned for a prefix and so a NullPointer occurs.
Comment 1 Matt MacIvor CLA 2010-06-30 12:39:23 EDT
Created attachment 173127 [details]
Proposed Fix and Test Case
Comment 2 Matt MacIvor CLA 2010-06-30 16:04:04 EDT
Attached patch checked in to SVN in 2.1 and Trunk branches. 

Will appear in nightly builds starting with 20100701
Comment 3 Eclipse Webmaster CLA 2022-06-09 10:32:09 EDT
The Eclipselink project has moved to Github: https://github.com/eclipse-ee4j/eclipselink