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 245596 - IndexOutOfBoundsException: Invalid line index=-1 < 0
Summary: IndexOutOfBoundsException: Invalid line index=-1 < 0
Status: CLOSED FIXED
Alias: None
Product: cnd
Classification: Unclassified
Component: Editor (show other bugs)
Version: 8.0
Hardware: All All
: P3 normal (vote)
Assignee: Alexander Simon
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-07-11 15:43 UTC by kosmonaffft
Modified: 2015-07-09 10:12 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 210660


Attachments
stacktrace (2.73 KB, text/plain)
2014-07-11 15:43 UTC, kosmonaffft
Details

Note You need to log in before you can comment on or make changes to this bug.
Description kosmonaffft 2014-07-11 15:43:35 UTC
This issue was reported manually by sdedic.
It already has 1 duplicates 


Build: NetBeans IDE Dev (Build 201404130001)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.0-b70, Java(TM) SE Runtime Environment, 1.8.0-b132
OS: Windows 8

User Comments:
kosmonaFFFt: Invoke build...




Stacktrace: 
java.lang.IndexOutOfBoundsException: Invalid line index=-1 < 0
   at org.netbeans.modules.editor.lib2.document.LineRootElement.getElement(LineRootElement.java:80)
   at org.openide.text.NbDocument$DocumentRenderer.run(NbDocument.java:923)
   at org.netbeans.editor.BaseDocument.render(BaseDocument.java:1391)
   at org.openide.text.NbDocument$DocumentRenderer.renderToInt(NbDocument.java:898)
   at org.openide.text.NbDocument.findLineOffset(NbDocument.java:201)
   at org.netbeans.modules.editor.hints.HintsControllerImpl.computeLineSpan(HintsControllerImpl.java:145)
Comment 1 kosmonaffft 2014-07-11 15:43:36 UTC
Created attachment 148002 [details]
stacktrace
Comment 2 Svata Dedic 2014-07-11 15:44:41 UTC
The OutputListenerImpl seems to pass -1 as line index, which will eventually cause the IOOBE. Please investigate.
Comment 3 Alexander Simon 2014-08-12 10:50:18 UTC
fixed, change set:
http://hg.netbeans.org/cnd-main/rev/c51f6cdca101
Comment 4 Quality Engineering 2014-08-13 02:23:55 UTC
Integrated into 'main-silver', will be available in build *201408130001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/c51f6cdca101
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixed Bug #245596 IndexOutOfBoundsException: Invalid line index=-1 < 0
Comment 5 Quality Engineering 2014-09-17 12:16:03 UTC
Integrated into 'releases/release801', will be available in build *201409171118* or newer. Wait for official and publicly available build.

Changeset: http://hg.netbeans.org/releases/rev/3e12846892c7
User: Alexander Simon <alexvsimon@netbeans.org>
Log: fixed Bug #245596 IndexOutOfBoundsException: Invalid line index=-1 < 0
(transplanted from c51f6cdca10149dddea00729d80efc739de4473d)