Opened 6 years ago

Closed 6 years ago

#13965 closed bug (fixed)

Polling /dev/null does not conform to POSIX

Reported by: sfanxiang Owned by: nobody
Priority: normal Milestone: Unscheduled
Component: System/POSIX Version: R1/Development
Keywords: Cc:
Blocked By: Blocking:
Platform: All

Description

Polling /dev/null with POLLOUT results in POLLOUT | POLLERR | POLLHUP, but the POSIX specification shows:

POLLHUP

... This event and POLLOUT are mutually-exclusive; a stream can never be writable if a hangup has occurred.

Change History (12)

comment:1 by sfanxiang, 6 years ago

Conceptual patches attached.

comment:2 by korli, 6 years ago

Have you eventually unit tests to attach?

comment:3 by sfanxiang, 6 years ago

Unit test attached.

comment:4 by sfanxiang, 6 years ago

For reference, this bug was discovered here:

https://github.com/haikuports/haikuports/pull/2124

comment:5 by pulkomandy, 6 years ago

Please submit patches at https://review.haiku-os.org rather than on the bugtracker.

comment:6 by sfanxiang, 6 years ago

Please submit patches at ​https://review.haiku-os.org rather than on the bugtracker.

Submitted as changes 64-68.

comment:7 by korli, 6 years ago

Resolution: fixed
Status: newclosed

Applied in hrev51811. Thanks!

Note: See TracTickets for help on using tickets.