mirror of
https://github.com/openjdk/jdk.git
synced 2026-05-15 08:03:50 +00:00
8080402: File Leak in jdk/src/java.base/share/classes/sun/net/sdp/SdpSupport.java
Reviewed-by: alanb, chegar, igerasim, msheppar
This commit is contained in:
parent
7beac309c0
commit
7c9b107d1f
@ -118,6 +118,8 @@ Java_sun_net_sdp_SdpSupport_convert0(JNIEnv *env, jclass cls, int fd)
|
||||
RESTARTABLE(dup2(s, fd), res);
|
||||
if (res < 0)
|
||||
JNU_ThrowIOExceptionWithLastError(env, "dup2");
|
||||
RESTARTABLE(close(s), res);
|
||||
res = close(s);
|
||||
if (res < 0 && !(*env)->ExceptionOccurred(env))
|
||||
JNU_ThrowIOExceptionWithLastError(env, "close");
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user