JFileChooser Win32ShellFolder2 pid
Hello,
I'm frequently experiencing a jvm crash two different winXP machines.
This happens when I open a JFileChooser instrumented with a FileSystemView.
The problem is both on jdk1.5.0_10 and on the new jdk1.6.0 final.
Googling around it seems that this is a quite common problem of the jdk on windows.
Here's an extract of the PID logs I get:
#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00000000, pid=412, tid=1392
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_10-b03 mixed mode)
# Problematic frame:
# C 0x00000000
#
T H R E A D
Current thread (0x439348e0): JavaThread"AWT-EventQueue-0" [_thread_in_native, id=1392]
siginfo: ExceptionCode=0xc0000005, reading address 0x00000000
Registers:
EAX=0x0015cfb8, EBX=0x45c1e768, ECX=0x0015d1e0, EDX=0x45c1e738
ESP=0x45c1e71c, EBP=0x45c1e75c, ESI=0x774b1a4c, EDI=0x45c1e758
EIP=0x00000000, EFLAGS=0x00010246
Top of Stack: (sp=0x45c1e71c)
0x45c1e71c:774fe75f 0015cfb8 774fe778 45c1e738
0x45c1e72c:45c1e73c 00000000 774b1a60 774fe49d
0x45c1e73c:00000000 00000000 45c1edc4 00000000
0x45c1e74c:00000000 00000000 00000000 0000a390
0x45c1e75c:45c1ef04 774ff1fb 45c1e768 774b4928
0x45c1e76c:774b45f8 774b45e8 00000001 00000338
0x45c1e77c:00000000 000000c0 46000000 00000000
0x45c1e78c:00000000 00000001 00000000 00000000
Instructions: (pc=0x00000000)
0xfffffff0:
Stack: [0x45b20000,0x45c20000), sp=0x45c1e71c, free space=1017k
Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j sun.awt.shell.Win32ShellFolder2.getNextChild(J)J+0
j sun.awt.shell.Win32ShellFolder2.listFiles(Z)[Ljava/io/File;+82
j sun.awt.shell.ShellFolder.listFiles()[Ljava/io/File;+2
j sun.awt.shell.Win32ShellFolderManager2.get(Ljava/lang/String;)Ljava/lang/Object;+181
j sun.awt.shell.ShellFolder.get(Ljava/lang/String;)Ljava/lang/Object;+4
j javax.swing.plaf.metal.MetalFileChooserUI.updateUseShellFolder()V+55
j javax.swing.plaf.metal.MetalFileChooserUI.installComponents(Ljavax/swing/JFileChooser;)V+67
j javax.swing.plaf.basic.BasicFileChooserUI.installUI(Ljavax/swing/JComponent;)V+47
j javax.swing.plaf.metal.MetalFileChooserUI.installUI(Ljavax/swing/JComponent;)V+2
j javax.swing.JComponent.setUI(Ljavax/swing/plaf/ComponentUI;)V+42
j javax.swing.JFileChooser.updateUI()V+40
j javax.swing.JFileChooser.setup(Ljavax/swing/filechooser/FileSystemView;)V+73
j javax.swing.JFileChooser.<init>(Ljava/io/File;Ljavax/swing/filechooser/FileSystemView;)V+133
j javax.swing.JFileChooser.<init>()V+9
#
# An unexpected error has been detected by HotSpot Virtual Machine:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00000000, pid=1532, tid=1228
#
# Java VM: Java HotSpot(TM) Client VM (1.5.0_10-b03 mixed mode)
# Problematic frame:
# C 0x00000000
#
T H R E A D
Current thread (0x439348e0): JavaThread"AWT-EventQueue-0" [_thread_in_native, id=1228]
siginfo: ExceptionCode=0xc0000005, reading address 0x00000000
Registers:
EAX=0x0015ce88, EBX=0x45c1e70c, ECX=0x0015d0b0, EDX=0x45c1e6dc
ESP=0x45c1e6c0, EBP=0x45c1e700, ESI=0x774b1a4c, EDI=0x45c1e6fc
EIP=0x00000000, EFLAGS=0x00010246
Top of Stack: (sp=0x45c1e6c0)
0x45c1e6c0:774fe75f 0015ce88 774fe778 45c1e6dc
0x45c1e6d0:45c1e6e0 00000000 774b1a60 774fe49d
0x45c1e6e0:00000000 00000000 45c1ed68 00000000
0x45c1e6f0:00000000 00000000 00000000 000092da
0x45c1e700:45c1eea8 774ff1fb 45c1e70c 774b4928
0x45c1e710:774b45f8 774b45e8 00000001 00000338
0x45c1e720:00000000 000000c0 46000000 00000000
0x45c1e730:00000000 00000001 00000000 00000000
Instructions: (pc=0x00000000)
0xfffffff0:
Stack: [0x45b20000,0x45c20000), sp=0x45c1e6c0, free space=1017k
Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j sun.awt.shell.Win32ShellFolder2.getNextChild(J)J+0
j sun.awt.shell.Win32ShellFolder2.listFiles(Z)[Ljava/io/File;+82
j sun.awt.shell.ShellFolder.listFiles()[Ljava/io/File;+2
j sun.awt.shell.Win32ShellFolderManager2.get(Ljava/lang/String;)Ljava/lang/Object;+181
j sun.awt.shell.ShellFolder.get(Ljava/lang/String;)Ljava/lang/Object;+4
j javax.swing.plaf.metal.MetalFileChooserUI.updateUseShellFolder()V+55
j javax.swing.plaf.metal.MetalFileChooserUI.installComponents(Ljavax/swing/JFileChooser;)V+67
j javax.swing.plaf.basic.BasicFileChooserUI.installUI(Ljavax/swing/JComponent;)V+47
j javax.swing.plaf.metal.MetalFileChooserUI.installUI(Ljavax/swing/JComponent;)V+2
j javax.swing.JComponent.setUI(Ljavax/swing/plaf/ComponentUI;)V+42
j javax.swing.JFileChooser.updateUI()V+40
j javax.swing.JFileChooser.setup(Ljavax/swing/filechooser/FileSystemView;)V+73
j javax.swing.JFileChooser.<init>(Ljava/io/File;Ljavax/swing/filechooser/FileSystemView;)V+133
j javax.swing.JFileChooser.<init>()V+9
#
# An unexpected error has been detected by Java Runtime Environment:
#
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x00000000, pid=3912, tid=648
#
# Java VM: Java HotSpot(TM) Client VM (1.6.0-b105 mixed mode)
# Problematic frame:
# C 0x00000000
#
# If you would like to submit a bug report, please visit:
#http://java.sun.com/webapps/bugreport/crash.jsp
#
T H R E A D
Current thread (0x43ab3000): JavaThread"AWT-EventQueue-0" [_thread_in_native, id=648]
siginfo: ExceptionCode=0xc0000005, reading address 0x00000000
Registers:
EAX=0x0015c810, EBX=0x45cadab8, ECX=0x0015ca38, EDX=0x45cada88
ESP=0x45cada6c, EBP=0x45cadaac, ESI=0x774b1a4c, EDI=0x45cadaa8
EIP=0x00000000, EFLAGS=0x00010246
Top of Stack: (sp=0x45cada6c)
0x45cada6c:774fc07a 0015c810 774bc4e8 45cada88
0x45cada7c:45cada8c 00000000 774b1a60 774fbdb8
0x45cada8c:00000000 00000000 45cae114 00000000
0x45cada9c:00000000 00000000 00000000 00002ec5
0x45cadaac:45cae254 774fcae5 45cadab8 774bca10
0x45cadabc:774bc6e0 774bc6d0 00000001 00000338
0x45cadacc:00000000 000000c0 46000000 00000000
0x45cadadc:00000000 00000001 00000000 00000000
Instructions: (pc=0x00000000)
0xfffffff0:
Stack: [0x45bb0000,0x45cb0000), sp=0x45cada6c, free space=1014k
Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j sun.awt.shell.Win32ShellFolder2.getDisplayNameOf(JJI)Ljava/lang/String;+0
j sun.awt.shell.Win32ShellFolder2.getFileSystemPath(JJ)Ljava/lang/String;+66
j sun.awt.shell.Win32ShellFolder2.<init>(Lsun/awt/shell/Win32ShellFolder2;J)V+7
j sun.awt.shell.Win32ShellFolder2.listFiles(Z)[Ljava/io/File;+171
j sun.awt.shell.ShellFolder.listFiles()[Ljava/io/File;+2
j sun.awt.shell.Win32ShellFolderManager2.get(Ljava/lang/String;)Ljava/lang/Object;+181
j sun.awt.shell.ShellFolder.get(Ljava/lang/String;)Ljava/lang/Object;+4
j javax.swing.plaf.metal.MetalFileChooserUI.updateUseShellFolder()V+55
j javax.swing.plaf.metal.MetalFileChooserUI.installComponents(Ljavax/swing/JFileChooser;)V+67
j javax.swing.plaf.basic.BasicFileChooserUI.installUI(Ljavax/swing/JComponent;)V+47
j javax.swing.plaf.metal.MetalFileChooserUI.installUI(Ljavax/swing/JComponent;)V+2
J javax.swing.JComponent.setUI(Ljavax/swing/plaf/ComponentUI;)V
j javax.swing.JFileChooser.updateUI()V+40
j javax.swing.JFileChooser.setup(Ljavax/swing/filechooser/FileSystemView;)V+18
j javax.swing.JFileChooser.<init>(Ljava/io/File;Ljavax/swing/filechooser/FileSystemView;)V+133
j javax.swing.JFileChooser.<init>()V+9
Can someone please give me a hint on how to avoid that bad crashes ?
Cheers,
Mik

