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

Bug 331614

Summary: NPE thrown in FlatVirtualComponent for variable mapped to folder
Product: [WebTools] WTP Common Tools Reporter: Jason Peterson <jasonpet>
Component: wst.commonAssignee: Jason Peterson <jasonpet>
Status: RESOLVED FIXED QA Contact: Carl Anderson <ccc>
Severity: normal    
Priority: P3 Flags: ccc: review+
Version: 3.2.2   
Target Milestone: 3.2.3   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
patch ccc: iplog+

Description Jason Peterson CLA 2010-12-01 16:54:29 EST
Created attachment 184310 [details]
patch

Variables that map to external folders will not be resolved and are not currently supported.  Users need to extend these folder variables for them to properly work.  Only workspace class folders are currently supported.  The following NPE is being thrown due to a missing check when encountering variables mapped to external folders:

Caused by: java.lang.NullPointerException
        at org.eclipse.wst.common.componentcore.internal.flat.VirtualComponentFlattenUtility.addContainer(VirtualComponentFlattenUtility.java:59)
        at org.eclipse.jst.common.internal.modulecore.AddClasspathFoldersParticipant.addClassFolderDependencies(AddClasspathFoldersParticipant.java:75)
        at org.eclipse.jst.common.internal.modulecore.AddClasspathFoldersParticipant.finalize(AddClasspathFoldersParticipant.java:56)
        at org.eclipse.wst.common.componentcore.internal.flat.FlatVirtualComponent.runFinalizations(FlatVirtualComponent.java:153)
        at org.eclipse.wst.common.componentcore.internal.flat.FlatVirtualComponent.cacheResources(FlatVirtualComponent.java:122)
        at org.eclipse.wst.common.componentcore.internal.flat.FlatVirtualComponent.fetchResources(FlatVirtualComponent.java:101)
        at
Comment 1 Carl Anderson CLA 2010-12-01 19:37:00 EST
Committed to R3_2_maintenance and HEAD for WTP 3.2.3 and WTP 3.3