From a11a46512876e6dfc34b7dbe49201b8907234e2d Mon Sep 17 00:00:00 2001 From: Kirill Tkhai Date: Mon, 10 Apr 2017 11:16:51 +0300 Subject: [PATCH] pid: Use last_level_pid() in restore_pgid() This patch is cleanup, which just makes comparation on values on the one pid level. It has no functional payload, because the new patches turn off pgid set if for multi-level pids cases, till it will be implemented. Signed-off-by: Kirill Tkhai --- criu/cr-restore.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/criu/cr-restore.c b/criu/cr-restore.c index f2e534977..3ad1791ba 100644 --- a/criu/cr-restore.c +++ b/criu/cr-restore.c @@ -1409,7 +1409,7 @@ static void restore_pgid(void) if (my_pgid == pgid) return; - if (my_pgid != vpid(current)) { + if (my_pgid != last_level_pid(current->pid)) { struct pstree_item *leader; /* @@ -1431,7 +1431,7 @@ static void restore_pgid(void) exit(1); } - if (my_pgid == vpid(current)) + if (my_pgid == last_level_pid(current->pid)) futex_set_and_wake(&rsti(current)->pgrp_set, 1); }