Bug 6693

Summary: AbstractImageBuilder.compile throws an ArrayIndexOutOfBoundsException on line 166 in build 20011206
Product: [Eclipse Project] JDT Reporter: Chris Dennis <Chris.Dennis>
Component: CoreAssignee: Kent Johnson <kent_johnson>
Status: RESOLVED FIXED QA Contact:
Severity: normal    
Priority: P1 CC: bquinn, chandu.mca23, sdowney
Version: 2.0   
Target Milestone: 2.0 M1   
Hardware: PC   
OS: Windows 2000   
Whiteboard:

Description Chris Dennis CLA 2001-12-07 17:42:38 EST
org.eclipse.jdt.internal.core.newbuilder.AbstractImageBuilder line 165 and 166 
are
initialNamesInLoop[index++] = typeName;
toCompile[index] = new SourceFile(filename,

The code on line 166 is allowed to reference an invalid array location once 
index == doNow.
Comment 1 Howard M. Lewis Ship CLA 2001-12-07 17:47:36 EST
I've been unable to build since installing this version of Eclipse.  I unpacked 
the eclipse distribution on top of my existing Eclipse ... is this incorrect?

I'm going to have to revert to the older Eclipse.
Comment 2 Philipe Mulet CLA 2001-12-07 17:51:58 EST
We will look into this asap, for the meantime you can revert to the old Java 
builder by changing the extension point inside 
<install>/eclipse/plugins/org.eclipse.jdt.core/plugin.xml

and modify it to have it look as below for the Java builder section.

<!-- 
=========================================================================== -->
<!-- Java 
Builder                                                                -->
<!-- 
=========================================================================== -->

<extension 
	point="org.eclipse.core.resources.builders" 
	id="javabuilder"
	name="%javaBuilderName">
	<builder>
	<!-- old builder 
is "org.eclipse.jdt.internal.core.builder.impl.JavaBuilder" -->
	<!-- new builder 
is "org.eclipse.jdt.internal.core.newbuilder.JavaBuilder" -->
		<run 
class="org.eclipse.jdt.internal.core.builder.impl.JavaBuilder">
		</run>
	</builder>
</extension>
Comment 3 Philipe Mulet CLA 2001-12-07 18:38:16 EST
Good find, the fix is to simply move the increment to the second line.
Will be fixed in next integration build.
Comment 4 Philipe Mulet CLA 2001-12-17 05:51:50 EST
*** Bug 6900 has been marked as a duplicate of this bug. ***
Comment 5 Philipe Mulet CLA 2002-01-08 07:34:05 EST
*** Bug 6924 has been marked as a duplicate of this bug. ***