Re: [RFC][PATCH 11/11] signal: Ignore all but multi-process signals that come in during fork.

From: Eric W. Biederman
Date: Fri Jul 13 2018 - 10:51:38 EST


Oleg Nesterov <oleg@xxxxxxxxxx> writes:

> That is why I tried to sugest another approach. copy_process() should always fail
> if signal_pending() == T, just the "real" signal should not disturb the forking
> thread unless the signal is fatal or multi-process.

I understand now why you are suggesting another approach. There are lot
of cases that could be affected by the removal of
"if (signal_pending()) return restart_syscall();" in copy_process.

I just shiver at the thought of leaving the code that way. That is just
leaving a mess for later and the signal handling code already has way
too many of those.

So I am going to try and work through all of the cases.

I might even implement queueing shared signals for after the fork. As
it is looking increasingly less difficult.

Eric