cifs: add check for returning value of SMB2_set_info_init
authorAnastasia Belova <abelova@astralinux.ru>
Wed, 16 Nov 2022 14:10:27 +0000 (17:10 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 26 Nov 2022 08:24:42 +0000 (09:24 +0100)
commit2ab2494162440b9edf4a244e23ec75b47d6f8b59
treeb37a5c304e9b75444bb73ece69b50bc45bb87aa8
parent5783abda58d62f6f53572dcc47de7ff41663a93c
cifs: add check for returning value of SMB2_set_info_init

[ Upstream commit a51e5d293dd1c2e7bf6f7be788466cd9b5d280fb ]

If the returning value of SMB2_set_info_init is an error-value,
exit the function.

Found by Linux Verification Center (linuxtesting.org) with SVACE.

Fixes: 0967e5457954 ("cifs: use a compound for setting an xattr")

Signed-off-by: Anastasia Belova <abelova@astralinux.ru>
Signed-off-by: Steve French <stfrench@microsoft.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
fs/cifs/smb2ops.c