RFR: JDK-8327468: Do not restart close if errno is EINTR [macOS/linux] [v2]
Matthias Baesken
mbaesken at openjdk.org
Mon Mar 11 09:03:54 UTC 2024
On Mon, 11 Mar 2024 08:50:09 GMT, Matthias Baesken <mbaesken at openjdk.org> wrote:
>> There are a number of places remaining in the linux/macOS native JDK codebase where we use the RESTARTABLE macro with close, but this is unwanted on Linux/macOS.
>
> Matthias Baesken has updated the pull request incrementally with one additional commit since the last revision:
>
> do not throw exception on close error
Looks like the return code of close is mostly (98-99 % ?) ignored in the JDK codebase. So probably we should follow for now the usual approach in this PR too.
Btw. there are some places in the codebase where the return code of close is checked/handled e.g.
https://github.com/openjdk/jdk/blob/f2b5ffdb8ea3c766f14bab1dfd7c3865cffa2ce8/src/java.base/unix/native/libnet/SdpSupport.c#L109
or
https://github.com/openjdk/jdk/blob/f2b5ffdb8ea3c766f14bab1dfd7c3865cffa2ce8/src/java.base/unix/native/libnio/ch/UnixDispatcher.c#L37
-------------
PR Comment: https://git.openjdk.org/jdk/pull/18164#issuecomment-1987915306
More information about the serviceability-dev
mailing list