IEEE Standards Interpretation for IEEE Std 1003.1™-2001 IEEE Standard Standard for Information Technology -- Portable Operating System Interface (POSIX®)
Copyright © 2006 by the Institute of Electrical and Electronics Engineers, Inc. 3 Park Avenue New York, New York 10016-5997 USA All Rights Reserved.
Interpretations are issued to explain and clarify the intent of a standard and do not constitute an alteration to the original standard. In addition, interpretations are not intended to supply consulting information. Permission is hereby granted to download and print one copy of this document. Individuals seeking permission to reproduce and/or distribute this document in its entirety or portions of this document must contact the IEEE Standards Department for the appropriate license. Use of the information contained in this document is at your own risk.
IEEE Standards Department Copyrights and Permissions 445 Hoes Lane, Piscataway, New Jersey 08855-1331, USA
Interpretation Request #101
Topic: ls -l output Relevant Sections: XCU ls
In the typical case where a file has no alternate or additional access control method, POSIX currently requires a ‹space› followed by at least one ‹blank› between the graphic characters of the first and second columns of an "ls -l" output line.
This appears to be an unintended consequence of POSIX, as common and longstanding practice is to output only a single space. Here is an example, taken from Solaris 10, listing a file with a link count equal to 100:
$ ls -l f
-rw-r--r-- 100 eggert faculty 0 May 15 22:31 f
Only a single space separates the first and second columns of output. (The output is the same regardless of whether /bin/ls or /usr/xpg4/bin/ls is used.) However, POSIX currently requires that a ‹space› must follow the "-", and that one or more ‹blank›s must then separate the ‹space› from the "100".
Change XCU page 574 line 22176 from:
"%c%s%s%s%c", ‹entry type›, ‹owner permissions›,
"%c%s%s%s%s", ‹entry type›, ‹owner permissions›,
Change XCU page 574 lines 22179-22181 from:
The ‹optional alternate access method flag› shall be a single ‹space› if there is no alternate or additional access control method associated with the file; otherwise a printable character shall be used.
The ‹optional alternate access method flag› shall be the empty string if there is no alternate or additional access control method associated with the file; otherwise it shall be a string containing a single printable character that is not a ‹blank›.
The standards states the requirements, and conforming implementations must conform to this. However, concerns have been raised about this which are being referred to the sponsor.
Rationale for Interpretation