Bug 19146 – std.process.spawnProcess: Set signal handlers are reset to SIG_DFL between fork-exec

Status
RESOLVED
Resolution
INVALID
Severity
enhancement
Priority
P1
Component
phobos
Product
D
Version
D2
Platform
All
OS
Linux
Creation time
2018-08-06T13:32:45Z
Last change time
2019-07-25T07:53:50Z
Assigned to
No Owner
Creator
Hiroki Noda

Comments

Comment #0 by kubo39 — 2018-08-06T13:32:45Z
It's a possibility that rewriteing global variables may be performed by singal handler,So set signal handlers are reset to SIG_DFL. In order to prevent race condition, it is necessary to mask signals once in the parent process before fork.
Comment #1 by kubo39 — 2019-07-25T07:53:50Z
I'm wrong, we don't have to care about race condition in this case when we don't use vfork().