[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

[libvirt] [PATCH 08/11] rpc: Need to virCommandFree on error path



---
 src/rpc/virnetsocket.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/src/rpc/virnetsocket.c b/src/rpc/virnetsocket.c
index 0158970..93980d6 100644
--- a/src/rpc/virnetsocket.c
+++ b/src/rpc/virnetsocket.c
@@ -704,6 +704,7 @@ int virNetSocketNewConnectSSH(const char *nodename,
 
     virBufferEscapeShell(&buf, netcat);
     if (virBufferError(&buf)) {
+        virCommandFree(cmd);
         virBufferFreeAndReset(&buf);
         virReportOOMError();
         return -1;
-- 
1.7.11.7


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]