[Libguestfs] [PATCH] guestfs_find: Fix memory leak of sysrootdir.
Richard W.M. Jones
rjones at redhat.com
Tue Oct 20 09:35:21 UTC 2009
This fixes a memory leak in the current code for guestfs_find
(in the daemon).
Rich.
--
Richard Jones, Virtualization Group, Red Hat http://people.redhat.com/~rjones
virt-p2v converts physical machines to virtual machines. Boot with a
live CD or over the network (PXE) and turn machines into Xen guests.
http://et.redhat.com/~rjones/virt-p2v
-------------- next part --------------
>From cefc644d58786b73b2baaa2c2912da2738d24511 Mon Sep 17 00:00:00 2001
From: Richard Jones <rjones at redhat.com>
Date: Tue, 20 Oct 2009 10:19:21 +0100
Subject: [PATCH] guestfs_find: Fix memory leak of sysrootdir.
---
daemon/find.c | 1 +
1 files changed, 1 insertions(+), 0 deletions(-)
diff --git a/daemon/find.c b/daemon/find.c
index b659eb6..c5d26d7 100644
--- a/daemon/find.c
+++ b/daemon/find.c
@@ -85,6 +85,7 @@ do_find (const char *dir)
free (sysrootdir);
return NULL;
}
+ free (sysrootdir);
if (verbose)
fprintf (stderr, "%s\n", cmd);
--
1.6.5.rc2
More information about the Libguestfs
mailing list