@@ -658,19 +658,19 @@ def __init__(self, loop, pipe, protocol, waiter=None, extra=None):
658658 # On AIX, the reader trick (to be notified when the read end of the
659659 # socket is closed) only works for sockets. On other platforms it
660660 # works for pipes and sockets. (Exception: OS X 10.4? Issue #19294.)
661- # On macOS, the trick misfires for named FIFOs (but not for pipes
662- # created with os.pipe(), which have st_nlink == 0): the write end
663- # polls as readable whenever unread data sits in the FIFO, and no
661+ # On macOS and Solaris , the trick misfires for named FIFOs (but not for
662+ # pipes created with os.pipe(), which have st_nlink == 0): the write
663+ # end polls as readable whenever unread data sits in the FIFO, and no
664664 # event is delivered when the read end is closed, so it can only
665- # ever report a false disconnection (gh-145030). The same xnu
665+ # ever report a false disconnection (gh-145030). The same XNU
666666 # behaviour applies on iOS/tvOS/watchOS (sys.platform is not
667667 # "darwin" there).
668- is_named_fifo_on_apple = (
669- sys .platform in {"darwin" , "ios" , "tvos" , "watchos" }
668+ is_named_fifo_without_close_event = (
669+ sys .platform in {"darwin" , "ios" , "tvos" , "watchos" , "sunos5" }
670670 and is_fifo and pipe_stat .st_nlink > 0 )
671671 if is_socket or (is_fifo
672672 and not sys .platform .startswith ("aix" )
673- and not is_named_fifo_on_apple ):
673+ and not is_named_fifo_without_close_event ):
674674 # only start reading when connection_made() has been called
675675 self ._loop .call_soon (self ._loop ._add_reader ,
676676 self ._fileno , self ._read_ready )
0 commit comments