vircgroup: Resolve Coverity RESOURCE_LEAK

Need to free 'root' and 'opts' before 'return -1' if symlink fails.

Signed-off-by: Wang Rui <moon.wangrui@huawei.com>
This commit is contained in:
Wang Rui
2014-09-03 15:00:19 -04:00
committed by John Ferlan
parent 4f2ad084bc
commit d01a062be6
+1 -1
View File
@@ -3757,7 +3757,7 @@ virCgroupIsolateMount(virCgroupPtr group, const char *oldroot,
_("Unable to symlink directory %s to %s"),
group->controllers[i].mountPoint,
group->controllers[i].linkPoint);
return -1;
goto cleanup;
}
}
}