JDK-8071424 : JCK test api/java_net/Socket/descriptions.html#Bind crashes on Windows
  • Type: Bug
  • Component: core-libs
  • Sub-Component: java.net
  • Affected Version: 9
  • Priority: P2
  • Status: Closed
  • Resolution: Fixed
  • OS: windows_7
  • Submitted: 2015-01-23
  • Updated: 2018-02-15
  • Resolved: 2015-01-26
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
8u152Fixed 9 b49Fixed
Related Reports
Duplicate :  
When running JCK 9 on Windows 7 amd64, test api/java_net/Socket/descriptions.html#Bind fails in MultiJVM mode with fatal error.
# A fatal error has been detected by the Java Runtime Environment:
# EXCEPTION_ACCESS_VIOLATION (0xc0000005) at pc=0x000000006d94ba37, pid=9888, tid=8532
# JRE version: Java(TM) SE Runtime Environment (9.0-b29) (build 1.9.0-ea-b29)
# Java VM: Java HotSpot(TM) 64-Bit Server VM (1.9.0-ea-b29 mixed mode windows-amd64 compressed oops)
# Problematic frame:
# V [jvm.dll+0x13ba37] alloc_object+0x7
# Failed to write core dump. Minidumps are not enabled by default on client versions of Windows
# An error report file with more information is saved as:
# W:\\tools\\tmp\\QATools2\\1380\\hs_err_pid9888.log
# If you would like to submit a bug report, please visit:
# http://bugreport.sun.com/bugreport/crash.jsp
result: Failed. unexpected exit code: exit code 1

Stack: [0x0000000002030000,0x0000000002230000],  sp=0x000000000222ea00,  free space=2042k
Native frames: (J=compiled Java code, j=interpreted, Vv=VM code, C=native code)
V  [jvm.dll+0x13ba37]  alloc_object+0x7
V  [jvm.dll+0x140ab7]  jni_NewObject+0xb7
C  [net.dll+0xca6b]  NET_SockaddrToInetAddress+0xa3
C  [net.dll+0x27d8]  Java_java_net_DualStackPlainSocketImpl_localAddress+0x68
C  0x0000000002512f94

Java frames: (J=compiled Java code, j=interpreted, Vv=VM code)
j  java.net.DualStackPlainSocketImpl.localAddress(ILjava/net/InetAddressContainer;)V+0
j  java.net.DualStackPlainSocketImpl.socketGetOption(ILjava/lang/Object;)I+16
j  java.net.AbstractPlainSocketImpl.getOption(I)Ljava/lang/Object;+213
j  java.net.PlainSocketImpl.getOption(I)Ljava/lang/Object;+5
j  java.net.Socket.getLocalAddress()Ljava/net/InetAddress;+19
j  javasoft.sqe.tests.api.java.net.Socket.BindTests.Socket0018()Ljavasoft/sqe/javatest/Status;+76
v  ~StubRoutines::call_stub
j  sun.reflect.NativeMethodAccessorImpl.invoke0(Ljava/lang/reflect/Method;Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+0
j  sun.reflect.NativeMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+100
j  sun.reflect.DelegatingMethodAccessorImpl.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+6
j  java.lang.reflect.Method.invoke(Ljava/lang/Object;[Ljava/lang/Object;)Ljava/lang/Object;+56
j  javasoft.sqe.javatest.lib.MultiTest.invokeTestCase(Ljava/lang/reflect/Method;)Ljavasoft/sqe/javatest/Status;+8
j  javasoft.sqe.javatest.lib.MultiTest.run([Ljava/lang/String;Ljava/io/PrintWriter;Ljava/io/PrintWriter;)Ljavasoft/sqe/javatest/Status;+152
j  javasoft.sqe.javatest.lib.MultiTest.run([Ljava/lang/String;Ljava/io/PrintStream;Ljava/io/PrintStream;)Ljavasoft/sqe/javatest/Status;+40
j  javasoft.sqe.tests.api.java.net.Socket.BindTests.main([Ljava/lang/String;)V+16
v  ~StubRoutines::call_stub

jti , jtr and core dump files are attached
jck test report is available by link http://moonblade.ru.oracle.com/set/java/jck/qa-results/jck/9/ea/b03/results/qac/1380-b03/report/html/kfl_newfailures.html

The JCK QA team has not observed this failure at our nightly runs on solaris.  It appears that this is a platform specific issue.

The issue was reproduced on two lab machines: jcklab53 (real machine) and spb23152 (devops vm).

Failure is reproducible on jdk9 b42.  QA has also reproduced this failure all the way back to build b09.  I do not think they have run the test in earlier (pre b09) 9 builds.

The refactoring in JDK-8025306 caused this issue.

It would appear that there is an initInetAddressIDs(..) call missing from the Windows Dual Stacks Socket implementation, Java_java_net_DualStackPlainSocketImpl_initIDs. A minimal test, run on Windows Server 2012 R2, reproduces the crash every time. public class UnboundTest { public static void main(String[] args) throws Exception { try (java.net.Socket soc = new java.net.Socket()) { soc.bind(null); soc.getLocalAddress(); } } }

Not sure if this should be filed against core-libs/java.net or hotspot.