commandtest: Resolve Coverity RESOURCE_LEAK

Since '62f263a73' - Coverity complains if the !pidfile path is taken,
then newfd1 would be leaked.
This commit is contained in:
John Ferlan 2014-08-22 10:30:44 -04:00
parent b9ff7393bc
commit e1d0471e58

View File

@ -1081,6 +1081,7 @@ static int test24(const void *unused ATTRIBUTE_UNUSED)
unlink(pidfile);
VIR_FREE(pidfile);
virCommandFree(cmd);
VIR_FORCE_CLOSE(newfd1);
/* coverity[double_close] */
VIR_FORCE_CLOSE(newfd2);
VIR_FORCE_CLOSE(newfd3);