Bug 70842

Summary: NegativeIndex exception in the PE binary Parser
Product: [Tools] CDT Reporter: Alain Magloire <alain>
Component: cdt-coreAssignee: Alain Magloire <alain>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P3 CC: hasse
Version: 2.0   
Target Milestone: 2.0.1   
Hardware: PC   
OS: Windows All   
Whiteboard:

Description Alain Magloire CLA 2004-07-26 14:22:42 EDT
------- Additional Comment #7 From Hasse  2004-07-19 02:16 -------

I'm getting kind of the same error.
Only I get the "NegativeArraySizeException"
when importing a large CDT project as 4526 files, 848 folders.
Using WinXp and Eclipse 3.0 Finale with CDT 2.0 Finale.
This project I'm importing has 52 exe files and 55 dll files.
Removing the exe files and do the import again fixes the error.
Here's the error. (dunno maybe i should call in a new bug report) 

An error occurred while traversing resources.
java.lang.NegativeArraySizeException
org.eclipse.cdt.utils.coff.PE.getAttribute(PE.java:496)
org.eclipse.cdt.utils.coff.parser.PEParser.getBinary(PEParser.java:50)
org.eclipse.cdt.internal.core.model.CModelManager.createBinaryFile
(CModelManager.java:550)
org.eclipse.cdt.internal.core.model.BinaryRunner.addChildIfBinary
(BinaryRunner.java:116)
org.eclipse.cdt.internal.core.model.BinaryRunner$Visitor.visit
(BinaryRunner.java:141)
org.eclipse.core.internal.resources.Resource$2.visit(Resource.java:108)
org.eclipse.core.internal.resources.Resource$1.visitElement(Resource.java:55)
org.eclipse.core.internal.watson.ElementTreeIterator.doIteration
(ElementTreeIterator.java:78)
org.eclipse.core.internal.watson.ElementTreeIterator.doIteration
(ElementTreeIterator.java:82)
org.eclipse.core.internal.watson.ElementTreeIterator.doIteration
(ElementTreeIterator.java:82)
org.eclipse.core.internal.watson.ElementTreeIterator.doIteration
(ElementTreeIterator.java:82)
org.eclipse.core.internal.watson.ElementTreeIterator.doIteration
(ElementTreeIterator.java:82)
org.eclipse.core.internal.watson.ElementTreeIterator.doIteration
(ElementTreeIterator.java:82)
org.eclipse.core.internal.watson.ElementTreeIterator.iterate
(ElementTreeIterator.java:123)
org.eclipse.core.internal.resources.Resource.accept(Resource.java:65)
org.eclipse.core.internal.resources.Resource.accept(Resource.java:106)
org.eclipse.core.internal.resources.Resource.accept(Resource.java:85)
org.eclipse.cdt.internal.core.model.BinaryRunner$1.run(BinaryRunner.java:59)
org.eclipse.core.internal.jobs.Worker.run(Worker.java:66)
Comment 1 Alain Magloire CLA 2004-07-26 14:28:55 EDT
Fix in head and the branch

Thanks Hasse.