]> git.baikalelectronics.ru Git - kernel.git/commitdiff
ocfs2: remove unneeded null check
authorDing Xiang <dingxiang@cmss.chinamobile.com>
Fri, 26 Oct 2018 22:02:48 +0000 (15:02 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Fri, 26 Oct 2018 23:25:18 +0000 (16:25 -0700)
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 <dingxiang@cmss.chinamobile.com>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Cc: Mark Fasheh <mark@fasheh.com>
Cc: Joel Becker <jlbec@evilplan.org>
Cc: Junxiao Bi <junxiao.bi@oracle.com>
Cc: Joseph Qi <jiangqi903@gmail.com>
Cc: Changwei Ge <ge.changwei@h3c.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/ocfs2/aops.c

index 302cd7caa4a7ff756479e8b79ae2f4c7d33e0628..da578ad4c08f4b5f5f66d3e7f3e5b5af77cff812 100644 (file)
@@ -1392,8 +1392,7 @@ retry:
 unlock:
        spin_unlock(&oi->ip_lock);
 out:
-       if (new)
-               kfree(new);
+       kfree(new);
        return ret;
 }