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 90483 - ArrayIndexOutOfBoundsException when trying to open a file
Summary: ArrayIndexOutOfBoundsException when trying to open a file
Status: RESOLVED DUPLICATE of bug 61438
Alias: None
Product: ide
Classification: Unclassified
Component: Code (show other bugs)
Version: 5.x
Hardware: All Windows Vista
: P3 blocker (vote)
Assignee: issues@ide
URL:
Keywords:
: 90628 90687 (view as bug list)
Depends on:
Blocks:
 
Reported: 2006-12-02 19:40 UTC by alegis
Modified: 2007-07-27 07:55 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
messages.log - error log (150.39 KB, text/plain)
2006-12-02 19:42 UTC, alegis
Details

Note You need to log in before you can comment on or make changes to this bug.
Description alegis 2006-12-02 19:40:45 UTC
This issue occurs on NB 5.0 IDE, 5.5 IDE and 6.0 M5

When trying to open a file (Wanted to add a JAR as library, but you can't use
ANY of the open file options in Netbans) an ArrayIndexOutOfBounds error occurs.

I wasn't sure in which component to list this bug.
Comment 1 alegis 2006-12-02 19:42:49 UTC
Created attachment 36440 [details]
messages.log - error log
Comment 2 Jean-francois Denise 2006-12-04 07:53:39 UTC
In order to better define the module owner, could you add any stack trace? We
should then be able to define where to route this bug.

JF.
Comment 3 Jean-francois Denise 2006-12-04 08:20:56 UTC
Found the attachement. No JMX in the picture. Could you reassigne it to ide
component?

JF.
Comment 4 Jiri Kovalsky 2006-12-05 15:26:10 UTC
Reassigning to utilities module for further evaluation.
Comment 5 Marian Petras 2006-12-06 11:40:48 UTC
The symptom of the bug and the exception's stack-trace remind me bug #61438 -
"None of the File-Open-Dialog type of dialog will open!". I guess they are
essentially the same, just the stack-trace is a little bit different due to a
different L&F used in Vista.

To approve or disprove my suspicion, could you download and run the simple test
case attached to bug report #61438, please? The direct link for the compiled
test is
<http://www.netbeans.org/nonav/issues/showattachment.cgi/24340/Main.class> and
(in case you are interested) the direct link for the test's source code is
<http://www.netbeans.org/nonav/issues/showattachment.cgi/24339/Main.java>. The
test has just 2,2 kB.
Comment 6 Marian Petras 2006-12-06 14:41:20 UTC
Note:
The reporter has answered off-line (via e-mail) that he gets an exception when
he runs the test application and presses the "Open" button in the application's
window.

See the beginning of the exception report below. It is exactly the same
exception report that is at the end of the attached messages.log file. The
conclusion is that the bug is not NetBeans-specific.

------------------------------------------------------

Exception in thread "AWT-EventQueue-0" java.lang.ArrayIndexOutOfBoundsException:
3184
________at_sun.awt.shell.Win32ShellFolder2.getFileChooserIcon(Win32ShellFolder2.java:748)
________at_sun.awt.shell.Win32ShellFolderManager2.get(Win32ShellFolderManager2.java:248)
________at_sun.awt.shell.ShellFolder.get (ShellFolder.java:221)
________at_com.sun.java.swing.plaf.windows.WindowsLookAndFeel$LazyWindowsIcon.createValue(WindowsLookAndFeel.java:1873)
________at_javax.swing.UIDefaults.getFromHashtable(UIDefaults.java:185)
        ...
Comment 7 alegis 2006-12-06 14:52:36 UTC
It seems that conclusion is correct, as I tried to execute that same file with 
Eclipe and got the same error.

I'll try to get the bug reported to Microsoft
Comment 8 Marian Petras 2006-12-06 16:06:36 UTC
alegis, although the stack-trace contains words like "Win32" and "windows", it
is no evidence that it is Microsoft's code. I believe it is Sun's code that is
only executed when run on the Windows platform.

I guess this bug has the same root cause as bug #61438 ("None of the
File-Open-Dialog type of dialog will open!") which is claimed to be caused by
JDK bug #6210674 (see http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6210674).

So the next step is to confirm that it is really the same. The JDK bug is only
reproducible with custom icons used for hard-drives. Do you use custom icons for
hard-drives? If your answer is "yes", it is really the same bug and I will
update the JDK bug report with the Vista-specific stack-trace. If the answer is
"no", we will continue finding the actual cause of the bug (probably with the
JDK developers).
Comment 9 Jana Maleckova 2006-12-08 08:46:18 UTC
*** Issue 90628 has been marked as a duplicate of this issue. ***
Comment 10 Jana Maleckova 2006-12-08 10:31:03 UTC
*** Issue 90687 has been marked as a duplicate of this issue. ***
Comment 11 novakm 2007-07-27 07:55:40 UTC
mpetras was right, seems like a duplicate of issue #61438. It should be fixed in latest build of JDK - you can also read
issue #95147 if you are intrested in further information.

*** This issue has been marked as a duplicate of 61438 ***