]> git.baikalelectronics.ru Git - kernel.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)
commit562fb5265f49663402b7a380c8be60af6601f28b
tree0cc1f93971aeff9b5d02c0b57def21ad0d0b56b1
parentc528e482a01f7ef3808cff4d55ffb62a40519fa7
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