]> Gentwo Git Trees - linux/.git/commit
smb/server: fix possible memory leak in smb2_read()
authorZhangGuoDong <zhangguodong@kylinos.cn>
Sat, 11 Oct 2025 16:47:59 +0000 (00:47 +0800)
committerSteve French <stfrench@microsoft.com>
Wed, 15 Oct 2025 11:03:09 +0000 (06:03 -0500)
commit6fced056d2cc8d01b326e6fcfabaacb9850b71a4
treec491924ae24dceb359981a5252601a8cbc158a20
parent39dec6cd888bde4171bd4b8fcf45f73ab684404d
smb/server: fix possible memory leak in smb2_read()

Memory leak occurs when ksmbd_vfs_read() fails.
Fix this by adding the missing kvfree().

Co-developed-by: ChenXiaoSong <chenxiaosong@kylinos.cn>
Signed-off-by: ChenXiaoSong <chenxiaosong@kylinos.cn>
Signed-off-by: ZhangGuoDong <zhangguodong@kylinos.cn>
Acked-by: Namjae Jeon <linkinjeon@kernel.org>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/smb/server/smb2pdu.c