[CRIU] [PATCH 06/12] crtools: dump pending signals
Andrey Wagin
avagin at gmail.com
Tue Dec 18 13:46:50 EST 2012
2012/12/18 Pavel Emelyanov <xemul at parallels.com>:
>> @@ -941,6 +942,12 @@ static int dump_task_core_all(pid_t pid, const struct proc_pid_stat *stat,
>> if (ret < 0)
>> goto err_free;
>>
>> + fd_core = open_image(CR_FD_PSIGNAL, O_DUMP, item->pid.virt);
>> + if (fd_core < 0)
>> + goto err_free;
>> + ret = parasite_dump_signal_seized(pid, ctl, fd_core, 0);
>> + close(fd_core);
>> +
>> err_free:
>> core_entry_free(core);
>> pr_info("----------------------------------------\n");
>> @@ -1567,6 +1584,13 @@ static int dump_one_task(struct pstree_item *item)
>> goto err_cure;
>> }
>>
>> + ret = parasite_dump_signal_seized(pid, parasite_ctl,
>> + fdset_fd(cr_fdset, CR_FD_SIGNAL), 1);
>> + if (ret) {
>> + pr_err("Can't dump pending signals (pid: %d)\n", pid);
>> + goto err_cure;
>> + }
>> +
>> ret = parasite_dump_sigacts_seized(parasite_ctl, cr_fdset);
>> if (ret) {
>> pr_err("Can't dump sigactions (pid: %d) with parasite\n", pid);
>
> Why can't we go to parasite code once? Or twice, but in one place?
>
Here is another problem. A thread args for a thread leader is saved
separate from other thread_args-s. I'm going to fix that.
More information about the CRIU
mailing list