JDK-8035941 : Bad global or local ref passed to JNI from java.net.DualStackPlainDatagramSocketImpl.socketLocalAddress
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 9
  • Priority: P2
  • Status: Closed
  • Resolution: Duplicate
  • Submitted: 2014-02-27
  • Updated: 2014-02-27
  • Resolved: 2014-02-27
Related Reports
Duplicate :  
Description
Intel Xeon 3112 MHz, 2 cores, 11G, Win32 / Windows 8 Enterprise
jdk 9 b03

To get crash: compile and run DatagramTest.java attached.
#
# A fatal error has been detected by the Java Runtime Environment:
#
#  EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x0000000075db16d7, pid=6712, tid=24244
#
# JRE version: Java(TM) SE Runtime Environment (9.0-b03) (build 1.9.0-ea-b03)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (25.0-b62 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# V  [jvm.dll+0x1316d7]  alloc_object+0x7



Comments
Checked this test with before and after versions with the fix for 8035653, and it's definitely the same issue.
27-02-2014

This is likely a dup of JDK-8035653, need to repeat the test with a build of jdk9/dev.
27-02-2014

java -Xcheck:jni DatagramTest FATAL ERROR in native method: Bad global or local ref passed to JNI at java.net.DualStackPlainDatagramSocketImpl.socketLocalAddress(Native Method) at java.net.DualStackPlainDatagramSocketImpl.socketGetOption(DualStackPlainDatagramSocketImpl.java:195) at java.net.AbstractPlainDatagramSocketImpl.getOption(AbstractPlainDatagramSocketImpl.java:343) at java.net.DatagramSocket.getLocalAddress(DatagramSocket.java:808) at java.net.DatagramSocket.getLocalSocketAddress(DatagramSocket.java:589) at DatagramTest.testPacketLength(DatagramTest.java:31) at DatagramTest.main(DatagramTest.java:9)
27-02-2014