Buggy code:
class DOMMethod extends DOMMember implements IDOMMethod { protected String fReturnType ; protected int [ ] fReturnTypeRange ; protected char [ ] fParameterList ; protected int [ ] fParameterRange ; protected char [ ] fExceptionList ; protected int [ ] fExceptionRange ; protected String fBody ; protected int [ ] fBodyRange ; protected String [ ] fParameterNames ; protected String [ ] fParameterTypes ; protected String [ ] fExceptions ; protected String [ ] fTypeParameters = new String [ 0 ] ; protected String fDefaultValue = null ; DOMMethod ( ) { } DOMMethod ( char [ ] document , int [ ] sourceRange , String name , int [ ] nameRange , int [ ] commentRange , int flags , int [ ] modifierRange , boolean isConstructor , String returnType , int [ ] returnTypeRange , String [ ] parameterTypes , String [ ] parameterNames , int [ ] parameterRange , String [ ] exceptions , int [ ] exceptionRange , int [ ] bodyRange ) { } DOMMethod ( char [ ] document , int [ ] sourceRange , String name , int [ ] nameRange , int flags , boolean isConstructor , String returnType , String [ ] parameterTypes , String [ ] parameterNames , String [ ] exceptions ) { } public void addException ( String name ) throws IllegalArgumentException { } public void addParameter ( String type , String name ) throws IllegalArgumentException { } protected void appendMemberBodyContents ( CharArrayBuffer buffer ) { } protected void appendMemberDeclarationContents ( CharArrayBuffer buffer ) { } protected void appendSimpleContents ( CharArrayBuffer buffer ) { } public String getBody ( ) { becomeDetailed ( ) ; if ( hasBody ( ) ) { if ( ( fBody ) != null ) { return fBody ; } else { <START_BUG> return new String ( CharOperation . subarray ( fDocument , fBodyRange [ 0 ] , ( ( fBodyRange [ 1 ] ) + 1 ) ) ) ; <END_BUG> } } else { return null ; } } protected String getConstructorName ( ) { } protected DOMNode getDetailedNode ( ) { } public String [ ] getExceptions ( ) { } protected char [ ] generateFlags ( ) { } public IJavaElement getJavaElement ( IJavaElement parent ) throws IllegalArgumentException { } protected int getMemberDeclarationStartPosition ( ) { } public String getName ( ) { } public int getNodeType ( ) { } public String [ ] getParameterNames ( ) { } public String [ ] getParameterTypes ( ) { } public String getReturnType ( ) { } protected char [ ] getReturnTypeContents ( ) { } protected boolean hasTrailingArrayQualifier ( ) { } public boolean isConstructor ( ) { } protected boolean isReturnTypeAltered ( ) { } public boolean isSignatureEqual ( IDOMNode node ) { } protected DOMNode newDOMNode ( ) { } protected void offset ( int offset ) { } public void setBody ( String body ) { } void setBodyRangeEnd ( int end ) { } public void setConstructor ( boolean b ) { } public void setExceptions ( String [ ] names ) { } public void setName ( String name ) { } public void setParameters ( String [ ] types , String [ ] names ) throws IllegalArgumentException { } public void setReturnType ( String name ) throws IllegalArgumentException { } protected void setReturnTypeAltered ( boolean typeAltered ) { } protected void setSourceRangeEnd ( int end ) { } protected void shareContents ( DOMNode node ) { } public String toString ( ) { } public void setDefault ( String defaultValue ) { } public String getDefault ( ) { } public String [ ] getTypeParameters ( ) { } public void setTypeParameters ( String [ ] typeParameters ) { } }

Fix:
return new String ( fDocument , fBodyRange [ 0 ] , ( ( ( fBodyRange [ 1 ] ) + 1 ) - ( fBodyRange [ 0 ] ) ) ) ;