mirror of
https://github.com/checkpoint-restore/criu
synced 2025-09-03 15:55:53 +00:00
dump: Don't shadow the ret code with dump_namespaces
cr_dump_tasks does assign ret = -1 by default but dump_namespaces does shadow this variable with own error code so that if any subsequent calls will fail we will not notice the error. Signed-off-by: Cyrill Gorcunov <gorcunov@openvz.org> Acked-by: Andrew Vagin <avagin@openvz.org> Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
committed by
Pavel Emelyanov
parent
ea1ec9f619
commit
45b76a9a9a
@@ -1420,8 +1420,7 @@ int cr_dump_tasks(pid_t pid, const struct cr_options *opts)
|
|||||||
goto err;
|
goto err;
|
||||||
|
|
||||||
if (opts->namespaces_flags) {
|
if (opts->namespaces_flags) {
|
||||||
ret = dump_namespaces(pid, opts->namespaces_flags);
|
if (dump_namespaces(pid, opts->namespaces_flags) < 0)
|
||||||
if (ret < 0)
|
|
||||||
goto err;
|
goto err;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user