8150521: SharedSecrets.getJavaNetInetAddressAccess should ensure that InetAddress is initialised
Reviewed-by: alanb, chegar
--- a/jdk/src/java.base/share/classes/jdk/internal/misc/SharedSecrets.java Thu Mar 03 17:21:08 2016 +0000
+++ b/jdk/src/java.base/share/classes/jdk/internal/misc/SharedSecrets.java Thu Mar 03 17:27:35 2016 +0000
@@ -118,6 +118,8 @@
}
public static JavaNetInetAddressAccess getJavaNetInetAddressAccess() {
+ if (javaNetInetAddressAccess == null)
+ unsafe.ensureClassInitialized(java.net.InetAddress.class);
return javaNetInetAddressAccess;
}