Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 298332 - unresolved inclusion in external header causes StringIndexOutOfBoundsException
Summary: unresolved inclusion in external header causes StringIndexOutOfBoundsException
Status: RESOLVED FIXED
Alias: None
Product: PTP
Classification: Tools
Component: RDT (show other bugs)
Version: 2.1   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: 4.0   Edit
Assignee: Chris Recoskie CLA
QA Contact: Chris Recoskie CLA
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2009-12-21 13:47 EST by Mike Kucera CLA
Modified: 2010-09-23 14:59 EDT (History)
1 user (show)

See Also:


Attachments
patch for 2.1 (1.68 KB, patch)
2009-12-21 13:52 EST, Mike Kucera CLA
no flags Details | Diff
an additional fix applied to RSECIndexSubsystem (1.37 KB, patch)
2010-09-15 11:15 EDT, John Liu CLA
vivkong: iplog+
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Mike Kucera CLA 2009-12-21 13:47:14 EST
The error parsing code in RemoteCIndexSubsystem.reportProblem() can't handle the case when the fileName is not available. This can happen when when you specify some files to parse up front on the indexer preferences page and one of those files has an unresolved inclusion. Should be a simple fix.
Comment 1 Mike Kucera CLA 2009-12-21 13:52:24 EST
Created attachment 154893 [details]
patch for 2.1
Comment 2 Chris Recoskie CLA 2010-05-31 11:48:56 EDT
Did this ever get applied to HEAD?
Comment 3 Chris Recoskie CLA 2010-06-08 14:17:36 EDT
This would have gotten merged to HEAD in the big merge.
Comment 4 John Liu CLA 2010-09-15 11:15:06 EDT
Created attachment 178946 [details]
an additional fix applied to RSECIndexSubsystem


There is one flaw for the current fix, the way of checking if the header file is under the project(by indexof) may give an incorrect result, for example if the project dir is "/home/jwsliu/defects/6721" and header file name is
"/home/jwsliu/defects/6721_header/header.h", then header file will be parsed as
"header/header.h" under the project location, so we have to check if the file is existed or not.
Comment 5 Vivian Kong CLA 2010-09-23 14:59:08 EDT
(In reply to comment #4)
> Created an attachment (id=178946) [details]
> an additional fix applied to RSECIndexSubsystem
> 
> 
> There is one flaw for the current fix, the way of checking if the header file
> is under the project(by indexof) may give an incorrect result, for example if
> the project dir is "/home/jwsliu/defects/6721" and header file name is
> "/home/jwsliu/defects/6721_header/header.h", then header file will be parsed as
> "header/header.h" under the project location, so we have to check if the file
> is existed or not.

Applied to ptp_4_0 and HEAD.  Thanks John