NetBSD-Bugs archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: kern/60786: poll reports socket writable after shutdown(SHUT_WR)



The following reply was made to PR kern/60786; it has been noted by GNATS.

From: Robert Elz <kre%munnari.OZ.AU@localhost>
To: Taylor R Campbell <riastradh%NetBSD.org@localhost>
Cc: gnats-bugs%NetBSD.org@localhost, netbsd-bugs%NetBSD.org@localhost
Subject: Re: kern/60786: poll reports socket writable after shutdown(SHUT_WR)
Date: Fri, 25 Sep 2026 17:23:55 +0700

     Date:        Fri, 25 Sep 2026 01:24:10 +0000
     From:        Taylor R Campbell <riastradh%NetBSD.org@localhost>
     Message-ID:  <20260925012412.01FC684D78%mail.netbsd.org@localhost>
 
   | Oops, disregard -- that was a bad test I drafted too quickly.
 
 No problem, and I can certainly believe there are cases where
 select/poll aren't woken when they should be, lots has been added
 to the kernel since they were first created, and it would be easy
 for bugs to have slipped in.
 
 The only reason I replied initially, is because it is too easy to
 fall into the rabbit hole of believing that if select/poll say
 that an fd can be read/written, it should mean successfully.
 It doesn't, and never did - they were just a mechanism (long before
 BSD had O_NONBLOCK support in any form) to avoid hanging, and allow
 a semblance of fake threading (before that existed either).
 
 kre
 



Home | Main Index | Thread Index | Old Index