
From: Namjae Jeon <namjae.jeon@samsung.com> mainline inclusion from mainline-5.15-rc1 commit 27aa646db0f0465c5abf8e5cd545e070e7f14120 category: feature bugzilla: https://gitee.com/openeuler/kernel/issues/I60T7G CVE: NA Reference: https://git.kernel.org/torvalds/linux/c/27aa646db0f0 ------------------------------- Change error return instead of returning always success return. Reviewed-by: Dan Carpenter <dan.carpenter@oracle.com> Signed-off-by: Namjae Jeon <namjae.jeon@samsung.com> Signed-off-by: Steve French <stfrench@microsoft.com> Signed-off-by: Jason Yan <yanaijie@huawei.com> Signed-off-by: Zhong Jinghua <zhongjinghua@huawei.com> --- fs/cifsd/auth.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/cifsd/auth.c b/fs/cifsd/auth.c index 711f8dec38e1..5a56dd65fa06 100644 --- a/fs/cifsd/auth.c +++ b/fs/cifsd/auth.c @@ -1253,7 +1253,7 @@ int ksmbd_crypt_message(struct ksmbd_conn *conn, struct kvec *iov, key); if (rc) { ksmbd_err("Could not get %scryption key\n", enc ? "en" : "de"); - return 0; + return rc; } if (conn->cipher_type == SMB2_ENCRYPTION_AES128_GCM || -- 2.31.1