Skip to content

Commit

Permalink
cgroups/cgfsng: make sure pointer is NULL
Browse files Browse the repository at this point in the history
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
  • Loading branch information
Christian Brauner committed Nov 6, 2017
1 parent 411ac6d commit ae5e6c0
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/lxc/cgroups/cgfsng.c
Expand Up @@ -1187,6 +1187,8 @@ static void *cgfsng_init(struct lxc_handler *handler)
d->name = must_copy_string(handler->name);

/* copy per-container cgroup information */
d->cgroup_meta.dir = NULL;
d->cgroup_meta.controllers = NULL;
if (handler->conf) {
d->cgroup_meta.dir = must_copy_string(handler->conf->cgroup_meta.dir);
d->cgroup_meta.controllers = must_copy_string(handler->conf->cgroup_meta.controllers);
Expand Down

0 comments on commit ae5e6c0

Please sign in to comment.