This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Build: NetBeans IDE 7.2 (Build 201207171143) VM: Java HotSpot(TM) 64-Bit Server VM, 23.1-b03, Java(TM) SE Runtime Environment, 1.7.0_05-b05 OS: Linux User Comments: everflux: Tried to show annotation from git for existing javascript file. This may be the root cause of the NPE in Bug 216023 boonedox: git annotate Stacktrace: java.lang.ArrayIndexOutOfBoundsException: -1 at org.netbeans.libs.git.jgit.commands.BlameCommand$WAComparator.trimTrailingEoL(BlameCommand.java:141) at org.netbeans.libs.git.jgit.commands.BlameCommand$WAComparator.hashRegion(BlameCommand.java:124) at org.eclipse.jgit.diff.RawTextComparator.hash(RawTextComparator.java:262) at org.eclipse.jgit.diff.RawTextComparator.hash(RawTextComparator.java:54) at org.eclipse.jgit.diff.SubsequenceComparator.hash(SubsequenceComparator.java:77) at org.eclipse.jgit.diff.SubsequenceComparator.hash(SubsequenceComparator.java:56)
Created attachment 122424 [details] stacktrace
is your project open-source? Could i try and debug myself?
The project can not be made public, I am afraid. If there is any way I could help diagnosing the problem or testing a special build/run a nightly build, I am happy to do so.
blindly fixing: http://hg.netbeans.org/core-main/rev/d212ee5f8984
Integrated into 'main-golden', will be available in build *201208020001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/d212ee5f8984 User: Ondrej Vrabec <ovrabec@netbeans.org> Log: #216024 - ArrayIndexOutOfBoundsException: -1
*** Bug 219694 has been marked as a duplicate of this bug. ***
apparently not fixed
fix: http://hg.netbeans.org/core-main/rev/a561fa0a870e
Confirmed, no longer crashes for me now using custom build from core-main. Thanks! The last line of the file has no annotation, though. Removing the line (a blank line) the line then becoming the last line is missing the annotation information. Does not happen with other files, only with the one triggering the problem in previous builds.
Integrated into 'main-golden', will be available in build *201210090002* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/a561fa0a870e User: Ondrej Vrabec <ovrabec@netbeans.org> Log: #216024 - ArrayIndexOutOfBoundsException: -1 fixing wrong condition
please backport to 7.2
release72: http://hg.netbeans.org/releases/rev/754f48956135
Integrated into 'releases', will be available in build *201210100934* or newer. Wait for official and publicly available build. Changeset: http://hg.netbeans.org/releases/rev/754f48956135 User: Ondrej Vrabec <ovrabec@netbeans.org> Log: #216024 - ArrayIndexOutOfBoundsException: -1 fixing wrong condition (transplanted from a561fa0a870ef7e1c5623c647ae061481dd9f014)