summaryrefslogtreecommitdiff
path: root/fs
diff options
context:
space:
mode:
authoryangyun <yangyun50@huawei.com>2024-08-23 16:51:46 +0800
committerMiklos Szeredi <mszeredi@redhat.com>2024-08-28 18:10:29 +0200
commit3002240d16494d798add0575e8ba1f284258ab34 (patch)
tree4cac2ee0abefbd4af267de5244097762ad2faba0 /fs
parent97f30876c94382d1b01d45c2c76be8911b196527 (diff)
fuse: fix memory leak in fuse_create_open
The memory of struct fuse_file is allocated but not freed when get_create_ext return error. Fixes: 3e2b6fdbdc9a ("fuse: send security context of inode on file") Cc: stable@vger.kernel.org # v5.17 Signed-off-by: yangyun <yangyun50@huawei.com> Signed-off-by: Miklos Szeredi <mszeredi@redhat.com>
Diffstat (limited to 'fs')
-rw-r--r--fs/fuse/dir.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/fuse/dir.c b/fs/fuse/dir.c
index 2b0d4781f394..8e96df9fd76c 100644
--- a/fs/fuse/dir.c
+++ b/fs/fuse/dir.c
@@ -670,7 +670,7 @@ static int fuse_create_open(struct inode *dir, struct dentry *entry,
err = get_create_ext(&args, dir, entry, mode);
if (err)
- goto out_put_forget_req;
+ goto out_free_ff;
err = fuse_simple_request(fm, &args);
free_ext_value(&args);