On 11/26, Andrei Vagin wrote: > > > IOW, could you please explain how PTRACE_SETSIGMASK should be used, and why > > it doesn't do something like > > > > CRIU uses PTRACE_SETSIGMASK when it injects a parasite code into a > target process. In this case, we have to be sure that when the process > is resumed by PTRACE_CONT, it will not start handling signals and > executing signal handlers.
So iiuc CRUI uses PTRACE_SETSIGMASK to block all signals, run the parasite code, then restore the original sigmask. Assuming that CRIU also turns ERESTARTNOHAND into syscall-restart (I think it does ;) everything looks correct... OK, I think the patch is fine. Oleg.