]> git.ipfire.org Git - thirdparty/linux.git/commit
CIFS: Clarify SMB1 code for delete
authorSteve French <stfrench@microsoft.com>
Wed, 7 Jul 2021 02:42:08 +0000 (21:42 -0500)
committerSteve French <stfrench@microsoft.com>
Wed, 7 Jul 2021 16:53:17 +0000 (11:53 -0500)
commit2a780e8b64874ae5b4201a491799aef838da7bdd
tree0cc1f93971aeff9b5d02c0b57def21ad0d0b56b1
parente3973ea3a7c218c1e92bdbfe1da934ef69d7a4ed
CIFS: Clarify SMB1 code for delete

Coverity also complains about the way we calculate the offset
(starting from the address of a 4 byte array within the
header structure rather than from the beginning of the struct
plus 4 bytes) for SMB1 SetFileDisposition (which is used to
unlink a file by setting the delete on close flag).  This
changeset doesn't change the address but makes it slightly
clearer.

Addresses-Coverity: 711524 ("Out of bounds write")
Reviewed-by: Paulo Alcantara (SUSE) <pc@cjr.nz>
Signed-off-by: Steve French <stfrench@microsoft.com>
fs/cifs/cifssmb.c