Skip to content

Commit

Permalink
seize: fix error handling for check_freezer_cgroup
Browse files Browse the repository at this point in the history
When check_freezer_cgroup() has non-zero, `goto err` calls `return ret`.
However, the value of `ret` has been set to 0 in the lines above and
CRIU does not handle the error.

This problem is related to #2508

Signed-off-by: Radostin Stoyanov <rstoyanov@fedoraproject.org>
  • Loading branch information
rst0git committed Nov 4, 2024
1 parent dcc3b49 commit 63dc0f7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions criu/seize.c
Original file line number Diff line number Diff line change
Expand Up @@ -1032,6 +1032,7 @@ int collect_pstree(void)

pr_debug("Detected cgroup V%d freezer\n", cgroup_v2 ? 2 : 1);

ret = -1;
if (opts.freeze_cgroup && !freeze_cgroup_disabled) {
if (freeze_processes())
goto err;
Expand Down

0 comments on commit 63dc0f7

Please sign in to comment.