mirror of
git://github.com/lxc/lxc
synced 2025-08-31 02:17:58 +00:00
c/r: check that cgroup_num_hierarchies > 0
Otherwise in the error case, we end up subtracting two from the static_args, which would lead to a segfault :) Signed-off-by: Tycho Andersen <tycho.andersen@canonical.com>
This commit is contained in:
@@ -191,6 +191,7 @@ static void exec_criu(struct criu_opts *opts)
|
||||
return;
|
||||
}
|
||||
|
||||
if (cgroup_num_hierarchies() > 0)
|
||||
static_args += 2 * cgroup_num_hierarchies();
|
||||
|
||||
if (opts->user->verbose)
|
||||
|
Reference in New Issue
Block a user