git.annexia.org
/
libguestfs.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
7042c94
)
filesystems: Fix memory leak found by valgrind.
author
Richard W.M. Jones
<rjones@redhat.com>
Thu, 24 Nov 2011 15:49:27 +0000
(15:49 +0000)
committer
Richard W.M. Jones
<rjones@redhat.com>
Thu, 24 Nov 2011 21:07:16 +0000
(21:07 +0000)
(cherry picked from commit
cd3d28491dd19d25a6c04a8bc6a7ec94bded413b
)
cat/virt-filesystems.c
patch
|
blob
|
history
diff --git
a/cat/virt-filesystems.c
b/cat/virt-filesystems.c
index
de7a243
..
ac6466f
100644
(file)
--- a/
cat/virt-filesystems.c
+++ b/
cat/virt-filesystems.c
@@
-449,7
+449,7
@@
do_output_filesystems (void)
/* Skip swap and unknown, unless --extra flag was given. */
if (!(output & OUTPUT_FILESYSTEMS_EXTRA) &&
(STREQ (fses[i+1], "swap") || STREQ (fses[i+1], "unknown")))
-
continue
;
+
goto next
;
dev = canonical_device (fses[i]);
@@
-492,6
+492,8
@@
do_output_filesystems (void)
free (dev);
free (vfs_label);
free (vfs_uuid);
+
+ next:
free (fses[i]);
free (fses[i+1]);
}