--- a/src/java.base/windows/native/libnet/Inet4AddressImpl.c Wed Jul 18 14:44:04 2018 -0700
+++ b/src/java.base/windows/native/libnet/Inet4AddressImpl.c Thu Jan 18 13:55:26 2018 +0530
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2000, 2016, Oracle and/or its affiliates. All rights reserved.
+ * Copyright (c) 2000, 2018, Oracle and/or its affiliates. All rights reserved.
* DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
*
* This code is free software; you can redistribute it and/or modify it
@@ -146,7 +146,11 @@
}
setInetAddress_addr(env, iaObj, ntohl(((struct sockaddr_in *)
(iterator->ai_addr))->sin_addr.s_addr));
+ if ((*env)->ExceptionCheck(env))
+ goto cleanupAndReturn;
setInetAddress_hostName(env, iaObj, host);
+ if ((*env)->ExceptionCheck(env))
+ goto cleanupAndReturn;
(*env)->SetObjectArrayElement(env, ret, i++, iaObj);
iterator = iterator->ai_next;
}