]> www.infradead.org Git - users/jedix/linux-maple.git/commit
cifsd: Pass string length parameter to match_pattern()
authorNamjae Jeon <namjae.jeon@samsung.com>
Sun, 21 Mar 2021 08:32:19 +0000 (17:32 +0900)
committerSteve French <stfrench@microsoft.com>
Mon, 19 Apr 2021 00:20:49 +0000 (19:20 -0500)
commit073c576ad1aabbc58b887ad9e86b77b00a64762c
tree11edecbcd280a06d1ac1021575e76383d4dfd50e
parentf6873c9d9b46e7c5212486f8f113103d639571c3
cifsd: Pass string length parameter to match_pattern()

When iterating through a directory, a file's name may not be
null-terminated (depending on the underlying filesystem implementation).

Modify match_pattern to take the string's length into account when matching
it against the request pattern.

Signed-off-by: Marios Makassikis <mmakassikis@freebox.fr>
Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifsd/misc.c
fs/cifsd/misc.h
fs/cifsd/smb2pdu.c
fs/cifsd/smb_common.c