ubifs: Call iput(xino) only once in ubifs_purge_xattrs()
authorMarkus Elfring <elfring@users.sourceforge.net>
Thu, 26 Sep 2024 09:05:29 +0000 (11:05 +0200)
committerRichard Weinberger <richard@nod.at>
Thu, 14 Nov 2024 17:48:20 +0000 (18:48 +0100)
commitc6fa76da34ae4f2eb95ce3fb6c939285082515de
tree15b22458c06d2c947836fb87749ab25c205308fd
parent5580cdae05aefa96deebd7f5ade9d70c92adabd7
ubifs: Call iput(xino) only once in ubifs_purge_xattrs()

An iput(xino) call was immediately used after a return value check
for a remove_xattr() call in this function implementation.
Thus call such a function only once instead directly before the check.

This issue was transformed by using the Coccinelle software.

Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
Reviewed-by: Zhihao Cheng <chengzhihao1@huawei.com>
Signed-off-by: Richard Weinberger <richard@nod.at>
fs/ubifs/xattr.c