提交 f8a3deff 编写于 作者: M michaelm

7084560: Crash in net.dll

Reviewed-by: chegar
Contributed-by: luchsh@linux.vnet.ibm.com
上级 d4e57853
......@@ -504,8 +504,7 @@ jobject createNetworkInterface
*/
if (netaddrCount < 0) {
netaddrCount = enumAddresses_win(env, ifs, &netaddrP);
if ((*env)->ExceptionOccurred(env)) {
free_netaddr(netaddrP);
if (netaddrCount == -1) {
return NULL;
}
}
......
......@@ -194,8 +194,7 @@ int getAllInterfacesAndAddresses (JNIEnv *env, netif **netifPP)
while (curr != NULL) {
netaddr *netaddrP;
ret = enumAddresses_win(env, curr, &netaddrP);
if ((*env)->ExceptionOccurred(env)) {
free_netaddr(netaddrP);
if (ret == -1) {
return -1;
}
curr->addrs = netaddrP;
......@@ -449,8 +448,7 @@ static jobject createNetworkInterfaceXP(JNIEnv *env, netif *ifs)
*/
if (netaddrCount < 0) {
netaddrCount = enumAddresses_win(env, ifs, &netaddrP);
if ((*env)->ExceptionOccurred(env)) {
free_netaddr(netaddrP);
if (netaddrCount == -1) {
return NULL;
}
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册