On Thu, 3 Aug 2023 17:59:10 GMT, Alan Bateman <al...@openjdk.org> wrote:
>> com.sun.jndi.ldap.Connection::leanup does not close the underlying socket if >> the is an IOException generation when the output stream was flushing the >> buffer. >> >> Please refer to the bug https://bugs.openjdk.org/browse/JDK-8313657. > > src/java.naming/share/classes/com/sun/jndi/ldap/Connection.java line 658: > >> 656: unpauseReader(); >> 657: if (debug) { >> 658: if (sock.isClosed()) { > > How is it possible for sock.close() to succeed but isClosed to return false? It is an unreachable code and got removed. ------------- PR Review Comment: https://git.openjdk.org/jdk/pull/15143#discussion_r1283640395