2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-31 06:15:24 +00:00

dump: Don't loose dump_namespaces error

In case if dump_namespaces failed we may have
ret shadowed and erroneously report checkpoint
success.

Signed-off-by: Cyrill Gorcunov <gorcunov@gmail.com>
Signed-off-by: Andrei Vagin <avagin@virtuozzo.com>
This commit is contained in:
Cyrill Gorcunov
2018-06-04 20:17:57 +03:00
committed by Andrei Vagin
parent 7d8a6df24d
commit e7de24cdb5

View File

@@ -1985,9 +1985,11 @@ int cr_dump_tasks(pid_t pid)
if (ret)
goto err;
if (root_ns_mask)
if (dump_namespaces(root_item, root_ns_mask) < 0)
if (root_ns_mask) {
ret = dump_namespaces(root_item, root_ns_mask);
if (ret)
goto err;
}
ret = dump_cgroups();
if (ret)