RFR: 8280944: Enable Unix domain sockets in Windows Selector notification mechanism [v3]

Alan Bateman alanb at openjdk.java.net
Wed Feb 23 10:31:50 UTC 2022


On Wed, 23 Feb 2022 10:11:16 GMT, Daniel Fuchs <dfuchs at openjdk.org> wrote:

>> src/java.base/windows/classes/sun/nio/ch/PipeImpl.java line 182:
>> 
>>> 180:      */
>>> 181:     PipeImpl(SelectorProvider sp) throws IOException {
>>> 182:         this(sp, true, false);
>> 
>> I’m pretty sure that this should actually be:
>> Suggestion:
>> 
>>         this(sp, /*AF_UNIX*/ false, /*buffering*/ true);
>
> Good catch. I will log a bug for that.

> Good catch. I will log a bug for that. In practice (and fortunately) it doesn't really matter since AFAICT this constructor is never called.

The SelectorProvider's openPipe method creates the pipe implementation with the 1-arg constructor. The Selector creates the pipe for the wakeup mechanism with the 3-arg constructor. This PR is about the latter rather than the former. It is true that the comment in constructor description doesn't match the implementation but I read the comment from ExE-Boss to be asking for the openPipe to return an implementation that uses TCP sockets.

-------------

PR: https://git.openjdk.java.net/jdk/pull/7302


More information about the nio-dev mailing list