Signed-off-by: Dwight Engen <dwight.en...@oracle.com>
---
 src/lxc/cgroup.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/lxc/cgroup.c b/src/lxc/cgroup.c
index cf1605a..6aa4495 100644
--- a/src/lxc/cgroup.c
+++ b/src/lxc/cgroup.c
@@ -1688,6 +1688,8 @@ char *cgroup_to_absolute_path(struct cgroup_mount_point 
*mp, const char *path, c
 
        len = strlen(mp->mount_point) + strlen(path) + (suffix ? strlen(suffix) 
: 0);
        buf = calloc(len + 1, 1);
+       if (!buf)
+               return NULL;
        rv = snprintf(buf, len + 1, "%s%s%s", mp->mount_point, path, suffix ? 
suffix : "");
        if (rv > len) {
                free(buf);
-- 
1.8.3.1


------------------------------------------------------------------------------
Android is increasing in popularity, but the open development platform that
developers love is also attractive to malware creators. Download this white
paper to learn more about secure code signing practices that can help keep
Android apps secure.
http://pubads.g.doubleclick.net/gampad/clk?id=65839951&iu=/4140/ostg.clktrk
_______________________________________________
Lxc-devel mailing list
Lxc-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/lxc-devel

Reply via email to