9pfs: xattr: fix memory leak in v9fs_list_xattr
Free 'orig_value' in error path. Signed-off-by: Li Qiang <liqiang6-s@360.cn> Signed-off-by: Greg Kurz <groug@kaod.org>
This commit is contained in:
parent
5daf9b3025
commit
4ffcdef427
@ -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;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user