#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:
Has a Patch: no 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 Changed 15 months ago by sfanxiang

Conceptual patches attached.

comment:2 Changed 15 months ago by korli

Have you eventually unit tests to attach?

Changed 15 months ago by sfanxiang

comment:3 Changed 15 months ago by sfanxiang

Unit test attached.

comment:4 Changed 15 months ago by sfanxiang

For reference, this bug was discovered here:

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

comment:5 Changed 15 months ago by pulkomandy

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

comment:6 Changed 15 months ago by sfanxiang

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

Submitted as changes 64-68.

comment:7 Changed 14 months ago by korli

Resolution: fixed
Status: newclosed

Applied in hrev51811. Thanks!

Note: See TracTickets for help on using tickets.