From: Dan Carpenter Date: Wed, 31 Jan 2024 07:10:18 +0000 (+0300) Subject: smb: client: Fix a NULL vs IS_ERR() check in wsl_set_xattrs() X-Git-Tag: v6.9-rc1~130^2~10 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=e0e1e09b2c41d383a2483f2ee5227b724860ced1;p=thirdparty%2Fkernel%2Flinux.git smb: client: Fix a NULL vs IS_ERR() check in wsl_set_xattrs() This was intended to be an IS_ERR() check. The ea_create_context() function doesn't return NULL. Fixes: 1eab17fe485c ("smb: client: add support for WSL reparse points") Reviewed-by: Paulo Alcantara Signed-off-by: Dan Carpenter Signed-off-by: Steve French --- diff --git a/fs/smb/client/reparse.c b/fs/smb/client/reparse.c index b240ccc9c887c..24feeaa32280e 100644 --- a/fs/smb/client/reparse.c +++ b/fs/smb/client/reparse.c @@ -230,7 +230,7 @@ static int wsl_set_xattrs(struct inode *inode, umode_t _mode, } cc = ea_create_context(dlen, &cc_len); - if (!cc) + if (IS_ERR(cc)) return PTR_ERR(cc); ea = &cc->ea;