mirror of
https://github.com/checkpoint-restore/criu
synced 2025-08-31 14:25:49 +00:00
restore: Bring trivial locker back
Threads are better to be restored in serialized way otherwise if some error happened an error message will be screwed. Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
This commit is contained in:
@@ -1453,6 +1453,7 @@ static void sigreturn_restore(pid_t pstree_pid, pid_t pid)
|
||||
task_args->pid = pid;
|
||||
task_args->fd_core = fd_core;
|
||||
task_args->fd_self_vmas = fd_self_vmas;
|
||||
task_args->rst_lock = 0;
|
||||
|
||||
if (pstree_entry.nr_threads) {
|
||||
int i;
|
||||
@@ -1479,6 +1480,8 @@ static void sigreturn_restore(pid_t pstree_pid, pid_t pid)
|
||||
goto err;
|
||||
}
|
||||
|
||||
thread_args[i].rst_lock = &task_args->rst_lock;
|
||||
|
||||
pr_info("Thread %4d stack %8p heap %8p rt_sigframe %8p\n",
|
||||
i, (long)thread_args[i].mem_zone.stack,
|
||||
thread_args[i].mem_zone.heap,
|
||||
|
Reference in New Issue
Block a user