View Issue Details

IDProjectCategoryView StatusLast Update
00016481003.1(2016/18)/Issue7+TC2Shell and Utilitiespublic2024-06-11 09:07
Reportergeoffclare Assigned To 
PrioritynormalSeverityObjectionTypeClarification Requested
Status ClosedResolutionAccepted 
NameGeoff Clare
OrganizationThe Open Group
User Reference
Section1.4 Utility Description Defaults
Page Number2339
Line Number74433-74444
Interp Status---
Final Accepted Text
Summary0001648: Confusing description of ASYNCHRONOUS EVENTS default behaviour
DescriptionThe default behaviour described for signal handling in the ASYNCHRONOUS EVENTS section of 1.4 Utility Description Defaults is highly confusing because the word "default" is doing multiple jobs.

It also has a list of three items that at first sight seem inter-related, but the list is introduced with "... shall be one of the following", indicating that they are independent choices. By a strict reading, this gives implementations the freedom to do unexpected things (like be terminated by a signal that was inherited as ignored).

In addition, the second list item appears to be redundant as it includes the condition "when no action has been taken to change the default". Since this section is describing the default behaviour, the condition is always true and thus the second item is effectively just a repeat of the first.

Finally, the last paragraph of this section should be conditional on cases where the signal terminates the utility.
Desired ActionChange:
... the action taken as a result of the signal shall be one of the following:
  1. The action shall be that inherited from the parent according to the rules of inheritance of signal actions defined in the System Interfaces volume of POSIX.1-2017.

  2. When no action has been taken to change the default, the default action shall be that specified by the System Interfaces volume of POSIX.1-2017.

  3. The result of the utility's execution is as if default actions had been taken.
A utility is permitted to catch a signal, perform some additional processing (such as deleting temporary files), restore the default signal action (or action inherited from the parent process), and resignal itself.
to:
... the action taken as a result of the signal shall be as follows:
  • If the action inherited from the invoking process, according to to the rules of inheritance of signal actions defined in the System Interfaces volume of POSIX.1-2017, is for the signal to be ignored, the utility shall ignore the signal.

  • If the action inherited from the invoking process, according to to the rules of inheritance of signal actions defined in the System Interfaces volume of POSIX.1-2017, is the default signal action, the result of the utility's execution shall be as if the default signal action had been taken.
When the required action is for the signal to terminate the utility, the utility may catch the signal, perform some additional processing (such as deleting temporary files), restore the default signal action, and resignal itself.

Tagsapplied_after_i8d3, tc3-2008

Activities

geoffclare

2023-06-13 10:56

manager   bugnote:0006328

When applying this bug I noticed that the rationale in XRAT C.1.5 needed part of the same change made in the last sentence of the desired action, namely removing "(or action inherited from the parent process)", and I have made that change.

Issue History

Date Modified Username Field Change
2023-03-30 09:34 geoffclare New Issue
2023-03-30 09:34 geoffclare Name => Geoff Clare
2023-03-30 09:34 geoffclare Organization => The Open Group
2023-03-30 09:34 geoffclare Section => 1.4 Utility Description Defaults
2023-03-30 09:34 geoffclare Page Number => 2339
2023-03-30 09:34 geoffclare Line Number => 74433-74444
2023-03-30 09:34 geoffclare Interp Status => ---
2023-04-06 16:00 shware_systems Tag Attached: tc3-2008
2023-04-06 16:02 Don Cragun Status New => Resolved
2023-04-06 16:02 Don Cragun Resolution Open => Accepted
2023-04-06 16:02 Don Cragun Desired Action Updated
2023-04-06 16:04 Don Cragun Desired Action Updated
2023-06-13 10:56 geoffclare Note Added: 0006328
2023-06-13 10:56 geoffclare Status Resolved => Applied
2023-06-13 10:56 geoffclare Tag Attached: applied_after_i8d3
2024-06-11 09:07 agadmin Status Applied => Closed