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 114175 - java.lang.ArrayIndexOutOfBoundsException: -1
Summary: java.lang.ArrayIndexOutOfBoundsException: -1
Status: RESOLVED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Window System (show other bugs)
Version: 6.x
Hardware: All All
: P2 blocker (vote)
Assignee: Stanislav Aubrecht
URL: http://statistics.netbeans.org/except...
Keywords: RANDOM
Depends on:
Blocks:
 
Reported: 2007-08-29 23:44 UTC by paulr5930
Modified: 2009-09-18 20:24 UTC (History)
20 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 546


Attachments
stacktrace (2.94 KB, text/plain)
2007-08-29 23:44 UTC, paulr5930
Details
stacktrace (1.72 KB, text/plain)
2007-09-01 15:11 UTC, tkellerer
Details
stacktrace (2.05 KB, text/plain)
2008-10-16 13:03 UTC, Unknown
Details
stacktrace (2.05 KB, text/plain)
2009-01-22 22:20 UTC, Jesse Glick
Details

Note You need to log in before you can comment on or make changes to this bug.
Description paulr5930 2007-08-29 23:44:46 UTC
Build: NetBeans IDE Dev (Build 200708260000)
VM: Java HotSpot(TM) Client VM, 1.6.0_02-b05
OS: Windows XP, 5.1, x86

User Comments: 
Just sent a problem report for the same exception.
Comment 1 paulr5930 2007-08-29 23:44:54 UTC
Created attachment 47764 [details]
stacktrace
Comment 2 tkellerer 2007-09-01 15:11:12 UTC
Build: NetBeans IDE Dev (Build 200708300000)
VM: Java HotSpot(TM) Client VM, 1.6.0_01-b06
OS: Windows XP, 5.1, x86

User Comments: 
Comment 3 tkellerer 2007-09-01 15:11:15 UTC
Created attachment 47931 [details]
stacktrace
Comment 4 David Simonek 2007-09-03 13:55:44 UTC
Exception report shows that there is no single line of netbeans code, all is javax.swing code. Without reproducible
scenario, unfortunately we can't neither fix the bug nor report it to the JDK team.

Please reopen if you have steps for reproducing the issue, thanks.
Comment 5 Milos Kleint 2007-10-14 19:01:19 UTC
I have these steps to reproduce:

1. open the Search Javadoc Index component.
2. ignore the stone age UI/icons
3. search for something
4. scroll through the returned items list. occasionally but rather frequently I get this exception.
Comment 6 Stanislav Aubrecht 2007-10-26 14:06:24 UTC
reproduced on winxp, jdk 1.5 using mkleint's steps
Comment 7 Stanislav Aubrecht 2007-10-26 14:09:24 UTC
i tried increasing the delay before the javadoc is shown when changing selection in the search results. 
pls reopen if you can still reproduce it.

/cvs/javadoc/src/org/netbeans/modules/javadoc/search/IndexSearch.java,v  <--  IndexSearch.java
new revision: 1.71; previous revision: 1.70
Comment 8 martinoconnor 2007-12-10 12:14:23 UTC
Product Version: NetBeans IDE 6.0 (Build 200711261600)
Java: 1.6.0_03; Java HotSpot(TM) Client VM 1.6.0_03-b05
System: Windows XP version 5.1 running on x86; Cp1252; en_IE (nb)
Userdir: C:\Documents and Settings\moconnor\.netbeans\6.0

I have been able to reproduce this issue, essentially following the steps already listed.
Comment 9 Exceptions Reporter 2007-12-11 17:52:07 UTC
THIS ISSUE HAS 5 MORE DUPLICATES
Comment 10 Stanislav Aubrecht 2008-01-03 13:56:17 UTC
let's try a bit bigger timeout then

/cvs/javadoc/src/org/netbeans/modules/javadoc/search/IndexSearch.java,v  <--  IndexSearch.java
new revision: 1.74; previous revision: 1.73
Comment 11 pribyl 2008-04-04 16:13:08 UTC
Product Version: NetBeans IDE Dev (Build 200804032041)
Java: 1.6.0_10-beta; Java HotSpot(TM) Client VM 11.0-b11
System: Windows XP version 5.1 running on x86; Cp1252; en_US (nb)

Reopening. The same exception was just thrown.

using mkleint's steps, with little difference: 
1.I searched some expression in javaDoc Index Search (e.g. String)
2.I ignored the stone age UI/icons :)
3.I srolled up/down in the results window and clicked some link (e.g. ParseException)

Note: The exception was not thrown in 100% cases, but quite frequently (try the steps 1. - 3. several times and you will
encouter it too I guess)
Comment 12 Exceptions Reporter 2008-05-01 22:38:16 UTC
This issue has already 50 duplicates 
Comment 13 Lukas Hasik 2008-05-03 22:43:41 UTC
the number of duplicates is raising. Stando, please, look at it. It would be great to have fix for 6.5 M1
Comment 14 Stanislav Aubrecht 2008-06-17 17:50:58 UTC
fixed (hopefully:)

44bf34347a84
Comment 15 Petr Dvorak 2008-07-01 14:12:10 UTC
Product Version: NetBeans IDE Dev (Build 200807010102)
Java: 1.6.0_10-beta; Java HotSpot(TM) Client VM 11.0-b12
System: Linux version 2.6.24-19-generic running on i386; UTF-8; en_US (nb)

Sorry, Standa, I am reopening this issue as I experienced it in M1 build from 01/Jully.

I have downloaded the JavaDoc and I added it in platform manager to jdk6. I successfully searched for the "String" type
there. Then I typed "Dialog" in the java source code and I pressed Shift+F1. Then I got the exception just after the
search tab opened...

Unfortunately, these steps are not reproducible:(... 

http://statistics.netbeans.org/analytics/detail.do?id=71163
Comment 16 Stanislav Aubrecht 2008-07-24 13:34:40 UTC
another attempt

7d48d3f42e0d
Comment 17 Petr Dvorak 2008-09-09 11:58:41 UTC
Product Version: NetBeans IDE Dev (Build 200809081401)
Java: 1.5.0_14; Java HotSpot(TM) Client VM 1.5.0_14-b03
System: SunOS version 5.10 running on sparc; ISO646-US; en (nb)

... sorry Standa, seems to be still not fixed...

It can be quite reliably reproduced on SunRays (they are generally slower, so it is easier). Use JDK1.5 Platform with
attached JDK1.5 documentation. Just invoke JIS above "String" and hold keys Up/Down to scroll up/down for several
times... IDE either permanently freezes (#146633) or eventually throws this exception...

(Isn't this exception harmless? Cannot it be just ignored?)
Comment 18 sunbiz 2008-09-21 01:18:45 UTC
Build: NetBeans IDE Dev (Build 200808281401)
VM: Java HotSpot(TM) Client VM, 10.0-b22, Java(TM) SE Runtime Environment, 1.6.0_06-b02
OS: Linux, 2.6.24-19-generic, i386

User Comments:
sunbiz: Pressed Shift+F1 to view Javadoc and got this exception

GUEST: Clicking on a link in a javadoc screen

GUEST: I searched for a class in the "javadoc index search".

GUEST: clicked link of sqrt method in Javadoc in IDE (class java.lang.Math)

paulr5930: Searched for URL in Javadoc Index Search then clicked on first item: URL - Class in java.net

paulr5930: Just sent a problem report for the same exception.

GUEST: Viewing JavaDocs

paulr5930: I was using the Javadoc Index Search feature.

mkleint: searching for something in the Javadoc index search component, scrolling through the results, got this exception

kawkhins: clic on weg page of error report

GUEST: Browsing Javadoc search,
debugging project.

wfifi: build and run findbugs 1.3.0

kawkhins: Closing all documents, got exception, sending to Netbeans.
While NB was showing uploaddone, new exception.
In the meanwhile, the new tab created for displaying uploaddone, displayed during second with content of an old tab closed earlier (javadoc).

khaoz: Using shift+f1, search and click on some link in the javadoc api view.

GUEST: i think i was pressing shift-f1 to get help about the FrameView object

juhrik: Started IDE with clear userdir and opened Plugin Manager (Tools|Plugins). Suddenly the exception dialog appeared.

pribyl: Exception was thrown when I used Javadoc Index search (Shift+F1) and then clicked on some link in the bottom window

GUEST: using javadocs

GUEST: While browsing Javadoc Index Search

medovina: I was doing nothing in particular.

GUEST: Viewing the Javadoc Index Search

carhire_kid: Used the Javadoc Index Search for a duration of 10-15 minutes and selecting a search result.

joshis: I have downloaded the JavaDoc and I added it in platform manager to jdk6. Then I typed "Dialog" in the source code and I pressed Shift+F1.

gjmurphy: I installed NB 6.5 M1, Java SE edition. I started NB, clicked on Tools->Plugins, and then on Reload Catalog.

GUEST: Powering on netbeans on OS X 10.5.4 gave this error

cyhelsky: After Searching in the Javadoc index search view

GUEST: Searching the javadoc (Shift-F1). Clicked on a method link to see method comment/description.

GUEST: browsing 'available plugins'

tkellerer: Browsing Javadocs (Javadoc Index Search)

GUEST: click a link in java doc

sunbiz: Clicked link under Javadoc window

esmithbss: Installing downloaded plugins

GUEST: ${buildday}

antodasana: I'm not sure, but I think I had clicked the 'Back' button in the NB javadoc browser.

GUEST: searching in "javadoc index search". platform freebsd 7.0 amd64 dual core. diablo-jdk 6.

GUEST: Adding plugin "Code Template Tools"

GUEST: Opening javadoc version 1.5

GUEST: Clicking any link in javadoc Index search while browsing any topic

GUEST: ${buildday}

GUEST: Browsing the Javadoc

GUEST: ${buildday}

GUEST: ${buildday}

GUEST: Viewing Javadoc via Javadoc Index Search. Clicked on a method name in the list of methods, exception thrown (although javadoc scrolled down to method description)

joshis: Trying to navigate in Javadoc index search using Up/Down keys

pbowyer: Using Javadoc Index Search

GUEST: ${buildday}

sunbiz: Pressed Shift+F1 to view Javadoc and got this exception



Stacktrace: 
java.lang.ArrayIndexOutOfBoundsException: -1
        at javax.swing.text.BoxView.getOffset(BoxView.java:1084)
        at javax.swing.text.BoxView.childAllocation(BoxView.java:678)
        at javax.swing.text.CompositeView.getChildAllocation(CompositeView.java:215)
        at javax.swing.text.BoxView.getChildAllocation(BoxView.java:436)
        at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.calculateViewPosition(BasicTextUI.java:1978)
        at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.layoutContainer(BasicTextUI.java:1954)
Comment 19 Stanislav Aubrecht 2008-10-02 16:21:17 UTC
too many duplicates -> P2
Comment 20 Stanislav Aubrecht 2008-10-03 13:11:09 UTC
fixed (hopefully:)

2fbb9d8f9381
Comment 21 Quality Engineering 2008-10-07 06:04:30 UTC
Integrated into 'main-golden', will be available in build *200810070201* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/2fbb9d8f9381
User: S. Aubrecht <saubrecht@netbeans.org>
Log: #114175 - AIOOB
Comment 22 Exceptions Reporter 2008-10-14 16:27:28 UTC
Reopening - reproduced in NetBeans IDE Dev (Build 200810111401)
http://statistics.netbeans.org/exceptions/detail.do?id=127855
Comment 23 Antonin Nebuzelsky 2008-10-15 15:42:39 UTC
Not for 6.5 anymore.

Maybe not a P2 at all.
Comment 24 Stanislav Aubrecht 2008-10-15 15:46:00 UTC
looks to me like jdk bug: http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=5042872
but it's reported as fixed so i need to create a reproducible test case and file a new bug agains jdk

lowering priority as the user impact is very low in this case.
Comment 25 Stanislav Aubrecht 2008-10-16 09:43:58 UTC
(forgot to actually lower the priority)
Comment 26 Unknown 2008-10-16 13:03:21 UTC
Build: NetBeans IDE Dev (Build 200810111401)
VM: Java HotSpot(TM) 64-Bit Server VM, 10.0-b23, Java(TM) SE Runtime Environment, 1.6.0_07-b06
OS: Linux, 2.6.26-5.slh.6-sidux-amd64, amd64

User Comments: 


Stacktrace: 
java.lang.ArrayIndexOutOfBoundsException: -1
        at javax.swing.text.BoxView.getOffset(BoxView.java:1084)
        at javax.swing.text.BoxView.childAllocation(BoxView.java:678)
        at javax.swing.text.CompositeView.getChildAllocation(CompositeView.java:215)
        at javax.swing.text.BoxView.getChildAllocation(BoxView.java:436)
        at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.calculateViewPosition(BasicTextUI.java:1978)
        at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.layoutContainer(BasicTextUI.java:1954)
Comment 27 Unknown 2008-10-16 13:03:35 UTC
Created attachment 71961 [details]
stacktrace
Comment 28 Jesse Glick 2009-01-22 22:19:58 UTC
Build: NetBeans IDE Dev (Build 090122)
VM: Java HotSpot(TM) Client VM, 11.0-b16, Java(TM) SE Runtime Environment, 1.6.0_11-b03
OS: Linux, 2.6.27-9-generic, i386

User Comments: 
Reporting another exception.

Stacktrace: 
java.lang.ArrayIndexOutOfBoundsException: -1
        at javax.swing.text.BoxView.getOffset(BoxView.java:1084)
        at javax.swing.text.BoxView.childAllocation(BoxView.java:678)
        at javax.swing.text.CompositeView.getChildAllocation(CompositeView.java:215)
        at javax.swing.text.BoxView.getChildAllocation(BoxView.java:436)
        at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.calculateViewPosition(BasicTextUI.java:1979)
        at javax.swing.plaf.basic.BasicTextUI$UpdateHandler.layoutContainer(BasicTextUI.java:1955)
Comment 29 Jesse Glick 2009-01-22 22:20:06 UTC
Created attachment 76163 [details]
stacktrace
Comment 30 Stanislav Aubrecht 2009-05-04 07:39:40 UTC
not a P1 bug
Comment 31 Stanislav Aubrecht 2009-05-14 09:19:58 UTC
i tried fixing this again

core-main f6f8e9df5cf6