提交 fd10c4e1 编写于 作者: J Jim Meyering

cgroup.c: don't leak mem+FD upon OOM

* src/util/cgroup.c (virCgroupDetectPlacement): Close the mapping
FILE* also upon error.
上级 a16a9694
......@@ -183,6 +183,7 @@ static int virCgroupDetectPlacement(virCgroupPtr group)
return 0;
no_memory:
fclose(mapping);
return -ENOMEM;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册