Anonymous | Login | 2023-11-29 17:45 UTC |
Main | My View | View Issues | Change Log | Docs |
Viewing Issue Simple Details [ Jump to Notes ] | [ Issue History ] [ Print ] | ||||||
ID | Category | Severity | Type | Date Submitted | Last Update | ||
0000276 | [1003.1(2008)/Issue 7] System Interfaces | Comment | Clarification Requested | 2010-07-02 15:56 | 2011-06-23 15:32 | ||
Reporter | fahree | View Status | public | ||||
Assigned To | |||||||
Priority | normal | Resolution | Rejected | ||||
Status | Closed | ||||||
Name | Francois-Rene Rideau | ||||||
Organization | |||||||
User Reference | |||||||
Section | (section number or name, can be interface name) | ||||||
Page Number | (page or range of pages) | ||||||
Line Number | (Line or range of lines) | ||||||
Interp Status | --- | ||||||
Final Accepted Text | |||||||
Summary | 0000276: declare vfork as async signal safe | ||||||
Description |
Since fork calls pthread_atfork handlers and cannot be async signal safe, could vfork be declared async signal safe, and could it be declared that between vfork and exec, any other async signal safe function could be called? That would allow for posix_spawn and extensions thereof to be implemented in terms of vfork. |
||||||
Desired Action |
Declare vfork async signal safe. Declare that in the vfork'ed process, any async signal safe function can be called. |
||||||
Tags | No tags attached. | ||||||
Attached Files | |||||||
|
![]() |
||||||
|
![]() |
|
(0000456) fahree (reporter) 2010-07-02 15:56 |
Related to issues 18 and 62. |
(0000458) geoffclare (manager) 2010-07-08 09:20 edited on: 2010-07-29 15:22 |
There is no vfork() function in the current standard. |
(0000477) fahree (reporter) 2010-07-29 15:25 |
It's of course OK if you ultimately decide to reject the issue, but could you at least include a rationale or explanation or note as to why the issue doesn't need be solved? |
(0000478) fahree (reporter) 2010-07-29 15:26 |
Note: vfork could be added back to the standard, in a way that is trivially backward compatible with previous standards and common practice. |
(0000479) fahree (reporter) 2010-07-29 15:27 |
The issue being: fork does no more do some of the things it used to do, and there is currently no valid replacement for it in those contexts. |
(0000528) geoffclare (manager) 2010-08-19 15:39 edited on: 2010-08-19 15:41 |
The vfork() function had heavy restrictions on the child process. Quoting SUSv3: the behavior is undefined if the process created by vfork() either modifies any data other than a variable of type pid_t used to store the return value from vfork(), or returns from the function in which vfork() was called, or calls any other function before successfully calling _exit() or one of the exec family of functions. Therefore it is not a suitable solution to the issue of fork() async-signal-safety. The solution the group has decided to adopt is to add an _Fork() function in the next revision, as per 0000062 |
Mantis 1.1.6[^] Copyright © 2000 - 2008 Mantis Group |