[libvirt] [PATCH v2 3/3] virnetdev: Resolve Coverity RESOURCE_LEAK
John Ferlan
jferlan at redhat.com
Wed Oct 29 22:50:48 UTC 2014
virFileReadAll returns a chunk of memory that needs to be free'd when
done
Signed-off-by: John Ferlan <jferlan at redhat.com>
---
src/util/virnetdev.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/src/util/virnetdev.c b/src/util/virnetdev.c
index 4fea4cb..0c9c1f9 100644
--- a/src/util/virnetdev.c
+++ b/src/util/virnetdev.c
@@ -2200,6 +2200,7 @@ static int virNetDevGetMcastList(const char *ifname,
ret = 0;
cleanup:
+ VIR_FREE(buf);
VIR_FREE(entry);
return ret;
--
1.9.3
More information about the libvir-list
mailing list