-
Bug
-
Resolution: Unresolved
-
P4
-
8, 11
-
generic
-
generic
ADDITIONAL SYSTEM INFORMATION :
openjdk version "1.8.0_432"
OpenJDK Runtime Environment (Temurin)(build 1.8.0_432-b06)
OpenJDK 64-Bit Server VM (Temurin)(build 25.432-b06, mixed mode)
openjdk version "11.0.25" 2024-10-15
OpenJDK Runtime Environment Temurin-11.0.25+9 (build 11.0.25+9)
OpenJDK 64-Bit Server VM Temurin-11.0.25+9 (build 11.0.25+9, mixed mode)
A DESCRIPTION OF THE PROBLEM :
We first try to call String var1 = (new XEvent()).toString(); This can lead to the Hotspot report Java. Lang. ArrayIndexOutOfBoundsException.
But when before this increase call new JEditorPane. JEditorPaneAccessibleHypertextSupport (new JEditorPane ()); Can lead to AWTError Hotspot8 report, while ArrayIndexOutOfBoundsException Hotspot11 will still be report.
Here is the code involved, we provide the Jimple code for reproducing the bug.
import javax.swing.JEditorPane;
import sun.awt.X11.XEvent;
public class test {
public static void main(String[] var0) {
new JEditorPane.JEditorPaneAccessibleHypertextSupport(new JEditorPane());
String var1 = (new XEvent()).toString();
}
}
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
ArrayIndexOutOfBoundsException
ACTUAL -
AWTError
---------- BEGIN SOURCE ----------
public class test extends java.lang.Object
{
public void <init>()
{
test r0;
r0 := @this: test;
specialinvoke r0.<java.lang.Object: void <init>()>();
return;
}
public static void main(java.lang.String[])
{
java.lang.String r0;
javax.swing.JEditorPane$JEditorPaneAccessibleHypertextSupport r1;
javax.swing.JEditorPane r2;
sun.awt.X11.XEvent $r3;
r2 = new javax.swing.JEditorPane;
specialinvoke r2.<javax.swing.JEditorPane: void <init>()>();
r1 = new javax.swing.JEditorPane$JEditorPaneAccessibleHypertextSupport;
specialinvoke r1.<javax.swing.JEditorPane$JEditorPaneAccessibleHypertextSupport: void <init>(javax.swing.JEditorPane)>(r2);
$r3 = new sun.awt.X11.XEvent;
specialinvoke $r3.<sun.awt.X11.XEvent: void <init>()>();
r0 = virtualinvoke $r3.<sun.awt.X11.XEvent: java.lang.String toString()>();
return;
}
}
---------- END SOURCE ----------
openjdk version "1.8.0_432"
OpenJDK Runtime Environment (Temurin)(build 1.8.0_432-b06)
OpenJDK 64-Bit Server VM (Temurin)(build 25.432-b06, mixed mode)
openjdk version "11.0.25" 2024-10-15
OpenJDK Runtime Environment Temurin-11.0.25+9 (build 11.0.25+9)
OpenJDK 64-Bit Server VM Temurin-11.0.25+9 (build 11.0.25+9, mixed mode)
A DESCRIPTION OF THE PROBLEM :
We first try to call String var1 = (new XEvent()).toString(); This can lead to the Hotspot report Java. Lang. ArrayIndexOutOfBoundsException.
But when before this increase call new JEditorPane. JEditorPaneAccessibleHypertextSupport (new JEditorPane ()); Can lead to AWTError Hotspot8 report, while ArrayIndexOutOfBoundsException Hotspot11 will still be report.
Here is the code involved, we provide the Jimple code for reproducing the bug.
import javax.swing.JEditorPane;
import sun.awt.X11.XEvent;
public class test {
public static void main(String[] var0) {
new JEditorPane.JEditorPaneAccessibleHypertextSupport(new JEditorPane());
String var1 = (new XEvent()).toString();
}
}
EXPECTED VERSUS ACTUAL BEHAVIOR :
EXPECTED -
ArrayIndexOutOfBoundsException
ACTUAL -
AWTError
---------- BEGIN SOURCE ----------
public class test extends java.lang.Object
{
public void <init>()
{
test r0;
r0 := @this: test;
specialinvoke r0.<java.lang.Object: void <init>()>();
return;
}
public static void main(java.lang.String[])
{
java.lang.String r0;
javax.swing.JEditorPane$JEditorPaneAccessibleHypertextSupport r1;
javax.swing.JEditorPane r2;
sun.awt.X11.XEvent $r3;
r2 = new javax.swing.JEditorPane;
specialinvoke r2.<javax.swing.JEditorPane: void <init>()>();
r1 = new javax.swing.JEditorPane$JEditorPaneAccessibleHypertextSupport;
specialinvoke r1.<javax.swing.JEditorPane$JEditorPaneAccessibleHypertextSupport: void <init>(javax.swing.JEditorPane)>(r2);
$r3 = new sun.awt.X11.XEvent;
specialinvoke $r3.<sun.awt.X11.XEvent: void <init>()>();
r0 = virtualinvoke $r3.<sun.awt.X11.XEvent: java.lang.String toString()>();
return;
}
}
---------- END SOURCE ----------