From: Ding Xiang Date: Fri, 26 Oct 2018 22:02:48 +0000 (-0700) Subject: ocfs2: remove unneeded null check X-Git-Tag: v4.20-rc1~92^2~122 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=0ae1c2dbdccc090762eb3c89183d7fc80dafca76;p=thirdparty%2Flinux.git ocfs2: remove unneeded null check Null check for kfree is unnecessary, so remove it. Link: http://lkml.kernel.org/r/1535704514-26559-1-git-send-email-dingxiang@cmss.chinamobile.com Signed-off-by: Ding Xiang Reviewed-by: Andrew Morton Cc: Mark Fasheh Cc: Joel Becker Cc: Junxiao Bi Cc: Joseph Qi Cc: Changwei Ge Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/fs/ocfs2/aops.c b/fs/ocfs2/aops.c index 302cd7caa4a7f..da578ad4c08f4 100644 --- a/fs/ocfs2/aops.c +++ b/fs/ocfs2/aops.c @@ -1392,8 +1392,7 @@ retry: unlock: spin_unlock(&oi->ip_lock); out: - if (new) - kfree(new); + kfree(new); return ret; }