Bug 193088 - NPE when adding workspace root as include entry
Summary: NPE when adding workspace root as include entry
Status: RESOLVED FIXED
Alias: None
Product: CDT
Classification: Tools
Component: cdt-core (show other bugs)
Version: 4.0   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 4.0 RC4   Edit
Assignee: Markus Schorn CLA
QA Contact:
URL:
Whiteboard:
Keywords: contributed
Depends on:
Blocks:
 
Reported: 2007-06-18 06:34 EDT by Gerhard Schaber CLA
Modified: 2009-01-09 17:06 EST (History)
2 users (show)

See Also:


Attachments
Proposal for a fix (2.28 KB, patch)
2007-06-18 06:35 EDT, Gerhard Schaber CLA
bjorn.freeman-benson: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Gerhard Schaber CLA 2007-06-18 06:34:22 EDT
Build ID: v200706151545

Steps To Reproduce:
1. Add an include entry with workspace root as path to a path entry container

A NPE occurs in CViewLabelProvider when trying to make a relative path of the include path. IContainer.getProject() is null for workspace root.


More information:
In addition to the proposed fix, I added a fix for CCommandDSC to make the resource lookup according to that of CViewLabelProvider.
Comment 1 Gerhard Schaber CLA 2007-06-18 06:35:01 EDT
Created attachment 71595 [details]
Proposal for a fix
Comment 2 Markus Schorn CLA 2007-06-18 09:34:42 EDT
Thanks Gerhard, I have applied your patch.