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.

Bug 200363 - java.source.pretty.CharBuffer: ArrayIndexOutOfBoundsException: -1
Summary: java.source.pretty.CharBuffer: ArrayIndexOutOfBoundsException: -1
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Source (show other bugs)
Version: 7.0
Hardware: All All
: P3 normal (vote)
Assignee: Svata Dedic
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-07-25 15:26 UTC by _ gtzabari
Modified: 2014-09-19 15:51 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 180119


Attachments
stacktrace (5.36 KB, text/plain)
2011-07-25 15:26 UTC, _ gtzabari
Details
stacktrace (5.36 KB, text/plain)
2013-05-03 22:10 UTC, Exceptions Reporter
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ gtzabari 2011-07-25 15:26:04 UTC
This bug was originally marked as duplicate of bug 138906, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE Dev (Build 201107220600)
VM: Java HotSpot(TM) Client VM, 21.0-b17, Java(TM) SE Runtime Environment, 1.7.0-b147
OS: Windows 7

User Comments:
gtzabari: Attempted to Override method inside enum




Stacktrace: 
java.lang.ArrayIndexOutOfBoundsException: -1
   at org.netbeans.modules.java.source.pretty.CharBuffer.eatAwayChars(CharBuffer.java:266)
   at org.netbeans.modules.java.source.pretty.VeryPretty.eatChars(VeryPretty.java:1949)
   at org.netbeans.modules.java.source.save.CasualDiff.copyTo(CasualDiff.java:3614)
   at org.netbeans.modules.java.source.save.CasualDiff.copyTo(CasualDiff.java:3602)
   at org.netbeans.modules.java.source.save.CasualDiff.diffNewClass(CasualDiff.java:1353)
   at org.netbeans.modules.java.source.save.CasualDiff.diffTreeImpl(CasualDiff.java:3204)
Comment 1 _ gtzabari 2011-07-25 15:26:08 UTC
Created attachment 109608 [details]
stacktrace
Comment 2 Exceptions Reporter 2012-12-19 18:58:39 UTC
This bug already has 5 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=180119
Comment 3 Exceptions Reporter 2013-05-03 22:10:41 UTC
Created attachment 134096 [details]
stacktrace

Using the 'Implement Method' option to implement a constant-specific method in a Java enum, declared as abstract within the enum class.
Comment 4 Exceptions Reporter 2013-07-26 00:36:51 UTC
This bug already has 10 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=180119
Comment 5 Svata Dedic 2014-08-29 21:19:45 UTC
Could not reproduce, but the method at the top of the stack might fail the way recorded in the log if eating away characters at the first printed line. 
Guard added in jet-main#1c62165e3ab4
Comment 6 Quality Engineering 2014-09-19 15:51:57 UTC
Integrated into 'main-silver', will be available in build *201409191429* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/1c62165e3ab4
User: Svata Dedic <sdedic@netbeans.org>
Log: #200363: buffer underflow avoided