View Issue Details

IDProjectCategoryView StatusLast Update
00003091003.1(2008)/Issue 7Shell and Utilitiespublic2013-04-16 13:06
Reportergeoffclare Assigned Toajosey  
PrioritynormalSeverityObjectionTypeClarification Requested
Status ClosedResolutionAccepted As Marked 
NameGeoff Clare
OrganizationThe Open Group
User Reference
Sectionfind
Page Number2740
Line Number89180
Interp StatusApproved
Final Accepted TextSee 0000309:0000562
Summary0000309: find -exec a b{} {} +
DescriptionThe requirements for the find utility are unclear regarding the
following command:

    find . -exec a b{} {} +

At line 89178 the part of the -exec primary description relating to
the '+' terminator says:

    If more than one argument containing only the two characters "{}"
    is present, the behavior is unspecified.

This doesn't apply here because of the use of "only".

The next paragraph begins:

    If a utility_name or argument string contains the two characters
    "{}", but not just the two characters "{}", it is
    implementation-defined whether find replaces those two characters
    or uses the string without change.

This allows two behaviours. The second (using the string without
change) is straightforward; the problem is with the first
alternative. If the "{}" characters are replaced, what should
they be replaced with?

Two different solutions are proposed. Option 1 just requires the
string to be used without change and eliminates the problematic
alternative. Option 2 makes line 89178 apply to this case by
removing the word "only", thus making the behaviour unspecified.
In both cases the existing "not just the two characters" text is
moved to the part relating to the ';' terminator.
Desired ActionOption 1

Append to line 89179:

    If a utility_name or argument string contains the two characters
    "{}", but not just the two characters "{}", the string shall be
    used without change.

Delete the following text from line 89180 and append it to line 89164:

    If a utility_name or argument string contains the two characters
    "{}", but not just the two characters "{}", it is
    implementation-defined whether find replaces those two characters
    or uses the string without change.

Option 2

At line 89178 change:

    If more than one argument containing only the two characters "{}"
    is present, the behavior is unspecified.

to:

    If more than one argument containing the two characters "{}" is
    present, the behavior is unspecified.

Delete the following text from line 89180 and append it to line 89164:

    If a utility_name or argument string contains the two characters
    "{}", but not just the two characters "{}", it is
    implementation-defined whether find replaces those two characters
    or uses the string without change.
Tagstc1-2008

Relationships

related to 0000310 Closedajosey Missing word "only" in find -exec description 

Activities

nick

2010-10-07 15:42

manager   bugnote:0000562

Interpretation response
------------------------
The standard is unclear on this issue, and no conformance distinction can be made between alternative implementations based on this. This is being referred to the sponsor.

Rationale:
-------------
Option 2 in the desired action seems the most appropriate.

Notes to the Editor (not part of this interpretation):
-------------------------------------------------------
At line 89178 change:

    If more than one argument containing only the two characters "{}"
    is present, the behavior is unspecified.

to:

    If more than one argument containing the two characters "{}" is
    present, the behavior is unspecified.

Delete the following text from line 89180 and append it to line 89164:

    If a utility_name or argument string contains the two characters
    "{}", but not just the two characters "{}", it is
    implementation-defined whether find replaces those two characters
    or uses the string without change.

ajosey

2010-12-16 16:15

manager   bugnote:0000640

Comments are due on this interpretation by January 16 2011

Issue History

Date Modified Username Field Change
2010-09-15 09:24 geoffclare New Issue
2010-09-15 09:24 geoffclare Status New => Under Review
2010-09-15 09:24 geoffclare Assigned To => ajosey
2010-09-15 09:24 geoffclare Name => Geoff Clare
2010-09-15 09:24 geoffclare Organization => The Open Group
2010-09-15 09:24 geoffclare Section => find
2010-09-15 09:24 geoffclare Page Number => 2740
2010-09-15 09:24 geoffclare Line Number => 89180
2010-09-15 09:24 geoffclare Interp Status => ---
2010-09-15 09:29 geoffclare Relationship added related to 0000310
2010-10-07 15:42 nick Note Added: 0000562
2010-10-07 15:42 nick Status Under Review => Interpretation Required
2010-10-07 15:42 nick Resolution Open => Accepted As Marked
2010-10-07 15:43 nick Final Accepted Text => See 0000309:0000562
2010-10-07 15:45 geoffclare Tag Attached: tc1-2008
2010-10-14 16:38 geoffclare Interp Status --- => Pending
2010-12-16 16:15 ajosey Interp Status Pending => Proposed
2010-12-16 16:15 ajosey Note Added: 0000640
2011-01-18 12:29 ajosey Interp Status Proposed => Approved
2013-04-16 13:06 ajosey Status Interpretation Required => Closed