Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 317511 - Faulty logic in HandleFactory.createOpenable
Summary: Faulty logic in HandleFactory.createOpenable
Status: RESOLVED FIXED
Alias: None
Product: JSDT
Classification: WebTools
Component: General (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 3.2.1   Edit
Assignee: Chris Jaun CLA
QA Contact: Nitin Dahyabhai CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2010-06-21 16:12 EDT by Chris Jaun CLA
Modified: 2010-06-29 09:52 EDT (History)
0 users

See Also:
thatnitind: review+


Attachments
patch (1.82 KB, patch)
2010-06-21 16:13 EDT, Chris Jaun CLA
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Jaun CLA 2010-06-21 16:12:59 EDT
if (this.lastPkgFragmentRootPath == null
				|| !(resourcePath.startsWith(this.lastPkgFragmentRootPath)
					&& (rootPathLength = this.lastPkgFragmentRootPath.length()) > 0
					&& resourcePath.charAt(rootPathLength) == '/')) {

The above check is faulty because in JSDT, unlike JDT, it is possible to have a library container as a child of a source folder.

The lastPkgFragmentRootPath was getting screwed up and resulting in the incorrect creation of package fragments.
Comment 1 Chris Jaun CLA 2010-06-21 16:13:51 EDT
Created attachment 172365 [details]
patch
Comment 2 Chris Jaun CLA 2010-06-29 09:52:11 EDT
Patch checked in.