提交 02483b1d 编写于 作者: J John Ferlan

network: Need to free formatted addr in networkDnsmasqConfContents

Commit id '0b6336c2' formatted the 'addr', but didn't VIR_FREE it.

Found by Coverity.
上级 f9edff30
...@@ -969,6 +969,7 @@ networkDnsmasqConfContents(virNetworkObjPtr network, ...@@ -969,6 +969,7 @@ networkDnsmasqConfContents(virNetworkObjPtr network,
if (!addr) if (!addr)
goto cleanup; goto cleanup;
virBufferAsprintf(&configbuf, "%s\n", addr); virBufferAsprintf(&configbuf, "%s\n", addr);
VIR_FREE(addr);
} else { } else {
/* "don't forward requests for this domain" */ /* "don't forward requests for this domain" */
virBufferAddLit(&configbuf, "#\n"); virBufferAddLit(&configbuf, "#\n");
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册