View Issue Details

IDProjectCategoryView StatusLast Update
00000781003.1(2008)/Issue 7Base Definitions and Headerspublic2013-04-16 13:06
Reportergeoffclare Assigned Toajosey  
PrioritynormalSeverityObjectionTypeError
Status ClosedResolutionAccepted 
NameGeoff Clare
OrganizationThe Open Group
User Reference
Sectionfcntl.h
Page Number240
Line Number7874-7879
Interp Status
Final Accepted Text
Summary0000078: grouping of creation/other O_* flags
Description OBJECTION Enhancement Request Number 1
 gwc:xxxxxxxxxxxxx Bug in XBDd5.1 fcntl.h (rdvk# 1)
 [gwc mtk fcntl] Thu, 16 Oct 2008 17:37:35 +0100
 _____________________________________________________________________________

 The <fcntl.h> spec describes various groups of flags for open() and
 openat(). Among them, the file creation flags at lines 7826 to 7834:

 ===
 The <fcntl.h> header shall define the following symbolic constants as
 file creation flags for use
 in the oflag value to open() and openat(). The values shall be
 bitwise-distinct and shall be
 suitable for use in #if preprocessing directives.
 O_CREAT Create file if it does not exist.
 O_EXCL Exclusive use flag.
 O_NOCTTY Do not assign controlling terminal.
 O_TRUNC Truncate flag.
 O_TTY_INIT Set the termios structure terminal parameters to
 conforming behavior; see Section 11.2 (on page 205).
 ===

 Further down, AT LINES 7874 TO 7879, there is the following text
 describing "other" FLAGS:

 ===
 The <fcntl.h> header shall define the following symbolic constants as
 values for the flag used by
 open( ) and openat( ):
 O_CLOEXEC The FD_CLOEXEC flag associated with the new descriptor shall
 be set to close
 the file descriptor upon execution of an exec family function.
 O_DIRECTORY Fail if not a directory.
 O_NOFOLLOW Do not follow symbolic links.
 ===

 There are two problems I see here:

 a) The wording in the second passage is inconsistent with that in the
 first passage. It should make clear that those flags are to be
 inclusively ORed in 'oflag'.

 b) The other point, which is what led me to raise this report, is that
 the spec is unclear on what the real difference is between these two
 groups of flags. Should they not all in fact be considered as one
 group. (For example, it's hard for me to understand why O_DIRECTORY
 is in one group, while say O_EXCL is in the other.)
Desired Action Delete lines 7874 to 7875.

 Relocate the flags described in the list at lines 7876 to 7879 (O_CLOEXEC,
 O_DIRECTORY and O_NOFOLLOW) into the list at lines 7829 to 7834 (O_CREAT
 through O_TTY_INIT).
Tagstc1-2008

Relationships

related to 0000432 Closedajosey 2008-TC1 confusing presentation of O_* list merge 

Activities

There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2009-06-29 08:47 geoffclare New Issue
2009-06-29 08:47 geoffclare Status New => Under Review
2009-06-29 08:47 geoffclare Assigned To => ajosey
2009-06-29 08:47 geoffclare Name => Geoff Clare
2009-06-29 08:47 geoffclare Organization => The Open Group
2009-06-29 08:47 geoffclare Section => fcntl.h
2009-06-29 08:47 geoffclare Page Number => 240
2009-06-29 08:47 geoffclare Line Number => 7874-7879
2009-06-29 08:53 geoffclare Status Under Review => Resolved
2009-06-29 08:53 geoffclare Resolution Open => Accepted
2009-06-29 08:54 geoffclare Tag Attached: real bug in aardvark
2009-08-06 15:41 geoffclare Tag Detached: real bug in aardvark
2010-08-19 16:56 ajosey Tag Attached: tc1
2010-08-27 10:36 ajosey Tag Renamed tc1 => tc1-2008
2011-05-13 15:13 eblake Relationship added related to 0000432
2013-04-16 13:06 ajosey Status Resolved => Closed