提交 6fba8c1f 编写于 作者: S Stefan Berger 提交者: Cole Robinson

nwfilter: Fix memory leak

Below patch fixes this coverity report:

/libvirt/src/conf/nwfilter_conf.c:382:
leaked_storage: Variable "varAccess" going out of scope leaks the storage it points to.

(cherry picked from commit b1675bac)
上级 870094c1
......@@ -375,6 +375,7 @@ virNWFilterRuleDefAddVar(virNWFilterRuleDefPtr nwf,
if (VIR_EXPAND_N(nwf->varAccess, nwf->nVarAccess, 1) < 0) {
virReportOOMError();
virNWFilterVarAccessFree(varAccess);
return -1;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册