bridge_driver: Resolve Coverity RESOURCE_LEAK

In the error path the 'ipaddr' wasn't VIR_FREE'd before jumping to cleanup
This commit is contained in:
John Ferlan 2014-08-27 15:15:05 -04:00
parent adedda2cc8
commit 2a4e26bdc1

View File

@ -993,6 +993,7 @@ networkDnsmasqConfContents(virNetworkObjPtr network,
"(as described in RFC1918/RFC3484/RFC4193)."),
ipaddr, (int)version / 1000000,
(int)(version % 1000000) / 1000);
VIR_FREE(ipaddr);
goto cleanup;
}
virBufferAsprintf(&configbuf, "listen-address=%s\n", ipaddr);