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

[libvirt] [PATCH] Fix memory leak in virCommandRun()



---
 src/util/command.c |    2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)

diff --git a/src/util/command.c b/src/util/command.c
index c0520ec..473d1fc 100644
--- a/src/util/command.c
+++ b/src/util/command.c
@@ -956,6 +956,8 @@ virCommandRun(virCommandPtr cmd, int *exitstatus)
         cmd->errbuf = NULL;
     }
 
+    VIR_FREE(outbuf);
+    VIR_FREE(errbuf);
     return ret;
 }
 
-- 
1.7.3


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