Files
linux-stable-mirror/fs/smb
Yiqi Sun ef9b1e6b8f smb: fix invalid username check in smb3_fs_context_parse_param()
[ Upstream commit ed6612165b ]

Since the maximum return value of strnlen(..., CIFS_MAX_USERNAME_LEN)
is CIFS_MAX_USERNAME_LEN, length check in smb3_fs_context_parse_param()
is always FALSE and invalid.

Fix the comparison in if statement.

Signed-off-by: Yiqi Sun <sunyiqixm@gmail.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
2025-12-12 18:37:20 +01:00
..