]> git.ipfire.org Git - thirdparty/lxc.git/commitdiff
coverity: #1425922
authorChristian Brauner <christian.brauner@ubuntu.com>
Thu, 7 Dec 2017 14:11:16 +0000 (15:11 +0100)
committerChristian Brauner <christian.brauner@ubuntu.com>
Sun, 17 Dec 2017 15:26:34 +0000 (16:26 +0100)
free allocated memory

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/lxc/cgroups/cgfsng.c

index 4c7df358ae334e00206c78dbec7969487116ec34..144c3b668626687b9222571d144dc7c6c2cf2359 100644 (file)
@@ -1721,6 +1721,7 @@ static bool cgfsng_mount(void *hdata, const char *root, int type)
                path2 = must_make_path(controllerpath, h->base_cgroup, d->container_cgroup, NULL);
                if (mkdir_p(path2, 0755) < 0) {
                        free(controllerpath);
+                       free(path2);
                        goto bad;
                }