]> 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>
Thu, 7 Dec 2017 14:11:16 +0000 (15:11 +0100)
free allocated memory

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

index 6089e95af95da29caecf1565a885e6a6c724808d..9c7213863408533ea17884f1581e9c11eccc3286 100644 (file)
@@ -1748,6 +1748,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;
                }