aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2017-04-10 16:08:37 +0100
committerPeter Maydell <peter.maydell@linaro.org>2017-04-10 16:08:37 +0100
commitc322fdd41ad5b313dab0b674154a22b3c665acce (patch)
tree618d6d0a28ab7ac559ac2ffb41f83a3fc2c89c35
parent0a49bfa1abaa7c7bea4505bef885a61fc910d055 (diff)
parent4ffcdef4277a91af15a3c09f7d16af072c29f3f2 (diff)
Merge remote-tracking branch 'remotes/gkurz/tags/for-upstream' into staging
Fixes a memory leak. # gpg: Signature made Mon 10 Apr 2017 13:20:39 BST # gpg: using DSA key 0x02FC3AEB0101DBC2 # gpg: Good signature from "Greg Kurz <groug@kaod.org>" # gpg: aka "Greg Kurz <groug@free.fr>" # gpg: aka "Greg Kurz <gkurz@linux.vnet.ibm.com>" # gpg: aka "Gregory Kurz (Groug) <groug@free.fr>" # gpg: aka "[jpeg image of size 3330]" # gpg: WARNING: This key is not certified with a trusted signature! # gpg: There is no indication that the signature belongs to the owner. # Primary key fingerprint: 2BD4 3B44 535E C0A7 9894 DBA2 02FC 3AEB 0101 DBC2 * remotes/gkurz/tags/for-upstream: 9pfs: xattr: fix memory leak in v9fs_list_xattr Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
-rw-r--r--hw/9pfs/9p-xattr.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/hw/9pfs/9p-xattr.c b/hw/9pfs/9p-xattr.c
index eec160b3c2..d05c1a1c1d 100644
--- a/hw/9pfs/9p-xattr.c
+++ b/hw/9pfs/9p-xattr.c
@@ -108,6 +108,7 @@ ssize_t v9fs_list_xattr(FsContext *ctx, const char *path,
g_free(name);
close_preserve_errno(dirfd);
if (xattr_len < 0) {
+ g_free(orig_value);
return -1;
}