]> Sergey Matveev's repositories - public-inbox.git/commit
spawn: proper signal handling for vfork
authorEric Wong <e@80x24.org>
Mon, 2 May 2016 08:48:46 +0000 (08:48 +0000)
committerEric Wong <e@80x24.org>
Mon, 2 May 2016 08:48:46 +0000 (08:48 +0000)
commitf6fa1ae2f5b17151abee45369afc9c6a8d89d1d6
treec5442002b32d3896fa33b268d2efb64c00698f7c
parent526a1e027cacf0c49092ae90b9b5d02c9d381705
spawn: proper signal handling for vfork

We cannot afford to fire Perl-level signal handlers in the
vforked child process since they're not designed to run in
the child like that.

Thus we need to block all signals before calling vfork, reset
signal dispositions in the child, and restore the signal mask in
the parent.

ref: https://ewontfix.com/7
lib/PublicInbox/Spawn.pm