nspawn: make sure to send SIGTERM/SIGHUP to the main nspawn process if stubinit recei...
authorLennart Poettering <lennart@poettering.net>
Fri, 23 Jun 2017 02:20:09 +0000 (04:20 +0200)
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 23 Jun 2017 02:20:09 +0000 (22:20 -0400)
commita462478539bd3c01c56c2f13413ea4b9ed6afbde
treefb7c31a055d020c2f93ac22d9cf698e510920346
parent9fe4a3d98e1fb5ac9782a0ef0a37c88260d3c8da
nspawn: make sure to send SIGTERM/SIGHUP to the main nspawn process if stubinit receives SIGRTMIN+3 (#6167)

This code already existed in some form, however commented. Remove the
comments, as this was most likely simply a forgotten commenting for
debugging purposes.

This also extends the logic a bit, by sending SIGHUP right after the
SIGTERM, so that shells will also terminate, when PID 1 gets a
SIGRTMIN+3.

Fixes: #5711
src/nspawn/nspawn-stub-pid1.c