-
Bug
-
Resolution: Cannot Reproduce
-
P4
-
None
-
6u21
-
x86
-
windows_xp
FULL PRODUCT VERSION :
C:\>java -version
java version "1.6.0_21"
Java(TM) SE Runtime Environment (build 1.6.0_21-b07)
Java HotSpot(TM) Client VM (build 17.0-b17, mixed mode, sharing)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows XP [Version 5.1.2600]
A DESCRIPTION OF THE PROBLEM :
This behavior was detected in the GUI of a much larger application. The pertinent root cause has been isolated, and is illustrated in the code snippet below (a simple main method).
If the call to make the caret visible is not commented out, the JVM will not close after it finishes the print statement.
If you comment out the call to make the caret visible, then the JVM properly closes after the print statement.
This behavior is not addressed in the JavaDoc which makes me believe it is a bug somewhere.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
SImply run the attached code snippet with and without commenting out the call to make the caret visible. When it is present, the JVM will not close properly.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
It was expected (in the above code snippet) the JVM will always close after main method terminates regardless of whether the caret was made visible or not.
ACTUAL -
If the call to make the caret visible is left in the code, then the JVM does not terminate properly.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
public static void main(String[] args) {
// Any old text area
JTextArea z = new JTextArea(new DefaultStyledDocument());
// Now try to show the caret
z.getCaret().setVisible(true);
// bread crumb to show that it reaches the end of this method
System.out.println("after call to caret...");
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
None found.
C:\>java -version
java version "1.6.0_21"
Java(TM) SE Runtime Environment (build 1.6.0_21-b07)
Java HotSpot(TM) Client VM (build 17.0-b17, mixed mode, sharing)
ADDITIONAL OS VERSION INFORMATION :
Microsoft Windows XP [Version 5.1.2600]
A DESCRIPTION OF THE PROBLEM :
This behavior was detected in the GUI of a much larger application. The pertinent root cause has been isolated, and is illustrated in the code snippet below (a simple main method).
If the call to make the caret visible is not commented out, the JVM will not close after it finishes the print statement.
If you comment out the call to make the caret visible, then the JVM properly closes after the print statement.
This behavior is not addressed in the JavaDoc which makes me believe it is a bug somewhere.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
SImply run the attached code snippet with and without commenting out the call to make the caret visible. When it is present, the JVM will not close properly.
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
It was expected (in the above code snippet) the JVM will always close after main method terminates regardless of whether the caret was made visible or not.
ACTUAL -
If the call to make the caret visible is left in the code, then the JVM does not terminate properly.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
public static void main(String[] args) {
// Any old text area
JTextArea z = new JTextArea(new DefaultStyledDocument());
// Now try to show the caret
z.getCaret().setVisible(true);
// bread crumb to show that it reaches the end of this method
System.out.println("after call to caret...");
}
---------- END SOURCE ----------
CUSTOMER SUBMITTED WORKAROUND :
None found.