From: John Ferlan Date: Tue, 8 Sep 2015 11:12:52 +0000 (-0400) Subject: tests: Resolve Coverity RESOURCE_LEAK X-Git-Url: http://xenbits.xensource.com/gitweb?a=commitdiff_plain;h=6743809dbf3d1704366de44c415118e76291cca6;p=people%2Fliuw%2Flibxenctrl-split%2Flibvirt.git tests: Resolve Coverity RESOURCE_LEAK In the error path need to unref the 'caps' as well Signed-off-by: John Ferlan --- diff --git a/tests/qemucaps2xmltest.c b/tests/qemucaps2xmltest.c index 6a5811c6c..7adde2469 100644 --- a/tests/qemucaps2xmltest.c +++ b/tests/qemucaps2xmltest.c @@ -113,6 +113,7 @@ testGetCaps(char *capsData, const testQemuData *data) error: virObjectUnref(qemuCaps); + virObjectUnref(caps); return NULL; }