8080486: JNI exception pending in jdk/src/java.base/windows/native/libnet/DualStackPlainSocketImpl.c
Reviewed-by: alanb, chegar, igerasim
Contributed-by: vyom.tewari@oracle.com
--- a/jdk/src/java.base/share/native/libnet/InetAddress.c Fri Sep 04 14:16:34 2015 -0700
+++ b/jdk/src/java.base/share/native/libnet/InetAddress.c Mon Sep 07 10:37:00 2015 +0200
@@ -57,6 +57,7 @@
c = (*env)->FindClass(env,"java/net/InetAddress$InetAddressHolder");
CHECK_NULL(c);
iac_class = (*env)->NewGlobalRef(env, c);
+ CHECK_NULL(iac_class);
ia_holderID = (*env)->GetFieldID(env, ia_class, "holder", "Ljava/net/InetAddress$InetAddressHolder;");
CHECK_NULL(ia_holderID);
ia_preferIPv6AddressID = (*env)->GetStaticFieldID(env, ia_class, "preferIPv6Address", "Z");
--- a/jdk/src/java.base/windows/native/libnet/DualStackPlainSocketImpl.c Fri Sep 04 14:16:34 2015 -0700
+++ b/jdk/src/java.base/windows/native/libnet/DualStackPlainSocketImpl.c Mon Sep 07 10:37:00 2015 +0200
@@ -45,9 +45,10 @@
jclass cls = (*env)->FindClass(env, "java/net/InetSocketAddress");
CHECK_NULL(cls);
isa_class = (*env)->NewGlobalRef(env, cls);
+ CHECK_NULL(isa_class);
isa_ctorID = (*env)->GetMethodID(env, cls, "<init>",
"(Ljava/net/InetAddress;I)V");
-
+ CHECK_NULL(isa_ctorID);
initInetAddressIDs(env);
// implement read timeout with select.