fuse: fix memory leak in fuse_create_open

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: yangyun <yangyun50@xxxxxxxxxx>

commit 3002240d16494d798add0575e8ba1f284258ab34 upstream.

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@xxxxxxxxxxxxxxx # v5.17
Signed-off-by: yangyun <yangyun50@xxxxxxxxxx>
Signed-off-by: Miklos Szeredi <mszeredi@xxxxxxxxxx>
Signed-off-by: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
---
 fs/fuse/dir.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/fs/fuse/dir.c
+++ b/fs/fuse/dir.c
@@ -741,7 +741,7 @@ static int create_new_entry(struct fuse_
 	err = fuse_simple_request(fm, args);
 	kfree(security_ctx);
 	if (err)
-		goto out_put_forget_req;
+		goto out_free_ff;
 
 	err = -EIO;
 	if (invalid_nodeid(outarg.nodeid) || fuse_invalid_attr(&outarg.attr))


Patches currently in stable-queue which might be from yangyun50@xxxxxxxxxx are

queue-6.1/fuse-fix-memory-leak-in-fuse_create_open.patch




[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux