#886 closed defect (fixed)
fcntl(F_GETFL) POSIX violation (non-blocking fd doesn't return O_NONBLOCK)
Reported by: | strauman | Owned by: | Jennifer Averett |
---|---|---|---|
Priority: | highest | Milestone: | 2 |
Component: | fs | Version: | 4.7 |
Severity: | critical | Keywords: | |
Cc: | bugs@…, joel.sherrill@… | Blocked By: | |
Blocking: |
Description
fcntl(fd,F_GETFL) fails to set O_NONBLOCK if the descriptor is in non-blocking mode.
This is because rtems_libio_to_fcntl_flags() is IMHO wrong. It returns O_NDELAY instead of O_NONBLOCK and worse, assumes a default value for O_NDELAY which is inconsistent with O_NONBLOCK. newlib 1.13 does not define O_NDELAY (nor, AFAIK, does POSIX).
Release:
4.6, 4.7
Environment:
n/a
How-To-Repeat:
assert ( O_NONBLOCK == rtems_libio_to_fcntl_flags(rtems_libio_fcntl_flags(O_NONBLOCK)) );
Attachments (1)
Change History (2)
comment:1 Changed on 03/07/06 at 20:02:49 by Joel Sherrill
Status: | assigned → closed |
---|
Note: See
TracTickets for help on using
tickets.
State-Changed-From-To: open->closed
State-Changed-Why: Patch applied to both 4.6 branch and head.