View Issue Details

IDProjectCategoryView StatusLast Update
0001687Issue 8 draftsBase Definitions and Headerspublic2024-06-11 09:12
Reportergeoffclare Assigned To 
PrioritynormalSeverityObjectionTypeClarification Requested
Status ClosedResolutionAccepted 
Product VersionDraft 3 
NameGeoff Clare
OrganizationThe Open Group
User Reference
Section5 File Format Notation
Page Number115
Line Number3632
Final Accepted Text
Summary0001687: Mismatch between blanks in file formats and default IFS
DescriptionIn the resolution of bug 0001532 the stty example code for restoring the terminal size uses awk because the stty utility is allowed to include blanks from the current locale (not just blank from the portable character set) around the numeric fields. It was mentioned in 0001532:0005661 that if we change XBD chapter 5 so that it allows implementations to add blanks only from the portable character set, then the example code could be changed back to using shell field splitting instead of using awk.

I believe the reason for allowing blanks around numeric fields was because of implementation differences noted during work on the original POSIX.2 drafts, such as the output of "wc -l" including leading blanks on some systems but not others. These differences at the time would only have involved space and tab characters, no other blanks, so there was no reason to allow other blanks in the original POSIX.2-1992 standard.

There are likely a large number of applications that expect to be able to use the default IFS to do field splitting on such output, and at the moment this is not guaranteed to work (in locales other than C and POSIX). We should change that.

For consistency, the other use of <blank> in XBD chapter 5 should change to match.
Desired ActionOn page 113 line 3543 section 5, change:
' ' (An empty character position.) Represents one or more <blank> characters.
to:
' ' (An empty character position.) Represents one or more <blank> characters from the portable character set.

On page 115 line 3632 section 5, change:
with <blank> characters
to:
with <blank> characters from the portable character set

On page 3379 line 115321 section stty, change:
stty size | awk '{printf "stty rows %d cols %d", $1, $2}'
to:
printf "stty rows %d cols %d" $(stty size)

Tagsapplied_after_i8d3, issue8

Relationships

related to 0001532 Closed "stty -g" output should not have to be split 

Activities

There are no notes attached to this issue.

Issue History

Date Modified Username Field Change
2023-05-03 10:30 geoffclare New Issue
2023-05-03 10:30 geoffclare Name => Geoff Clare
2023-05-03 10:30 geoffclare Organization => The Open Group
2023-05-03 10:30 geoffclare Section => 5 File Format Notation
2023-05-03 10:30 geoffclare Page Number => 115
2023-05-03 10:30 geoffclare Line Number => 3632
2023-05-03 10:32 geoffclare Relationship added related to 0001532
2023-06-15 15:48 Don Cragun Status New => Resolved
2023-06-15 15:48 Don Cragun Resolution Open => Accepted
2023-06-15 15:48 Don Cragun Tag Attached: issue8
2023-07-06 10:37 geoffclare Status Resolved => Applied
2023-07-06 10:37 geoffclare Tag Attached: applied_after_i8d3
2024-06-11 09:12 agadmin Status Applied => Closed