]> granicus.if.org Git - strace/commit
Do not reset SIGCHLD handler in tracees to SIG_DFL
authorDmitry V. Levin <ldv@altlinux.org>
Sat, 27 May 2017 15:58:54 +0000 (15:58 +0000)
committerDmitry V. Levin <ldv@altlinux.org>
Sat, 27 May 2017 17:59:44 +0000 (17:59 +0000)
commite97a66faa1dbc16555c00fe7a6e206619c0d0efe
tree9be5a07c04ef6f9715b1b1f154b26c1f527fc859
parente0fd7e7035e9306977de971f2176e8998eb8771b
Do not reset SIGCHLD handler in tracees to SIG_DFL

While strace resets SIGCHLD handler to the default action so that
waitpid definitely works without losing track of children, tracees
should not inherit this change.

* strace.c (struct exec_params): Add child_sa field.
(init): When setting SIGCHLD handler to SIG_DFL, save the old handler.
(exec_or_die): Restore SIGCHLD handler if it was different from SIG_DFL
at startup.
* NEWS: Mention this change.
NEWS
strace.c