[CRIU] [PATCH 2/3] compel: Improve infect
Cyrill Gorcunov
gorcunov at gmail.com
Thu Nov 24 03:54:08 PST 2016
On Thu, Nov 24, 2016 at 02:49:52PM +0300, Pavel Emelyanov wrote:
> > struct plain_regs_struct {
> > @@ -1135,6 +1165,10 @@ struct parasite_ctl *compel_prepare(int pid)
> > ictx->open_proc = simple_open_proc;
> > ictx->syscall_ip = find_executable_area(pid);
> > ictx->child_handler = handle_sigchld;
> > + ictx->orig_handler.sa_handler = SIG_DFL;
> > + ictx->orig_handler.sa_flags = SA_SIGINFO | SA_RESTART;
> > + sigemptyset(&ictx->orig_handler.sa_mask);
> > + sigaddset(&ictx->orig_handler.sa_mask, SIGCHLD);
> > sigaction(SIGCHLD, NULL, &ictx->orig_handler);
>
> Isn't sigaction() not enough to fill in the orig_handler?
It should be enough but I would like to be close to what
is done in criu.
More information about the CRIU
mailing list