ocfs2: fix d_splice_alias() return code checking
authorRichard Weinberger <richard@nod.at>
Wed, 29 Oct 2014 21:50:53 +0000 (14:50 -0700)
committerLinus Torvalds <torvalds@linux-foundation.org>
Wed, 29 Oct 2014 23:33:15 +0000 (16:33 -0700)
commitd3556babd7facb8fbc596bada0d67139e3b22330
treeee64a8efc40fd2604483dd01171700b0e14d7ad5
parent8186eb6a799e4e32f984b55858d8e393938be0c1
ocfs2: fix d_splice_alias() return code checking

d_splice_alias() can return a valid dentry, NULL or an ERR_PTR.
Currently the code checks not for ERR_PTR and will cuase an oops in
ocfs2_dentry_attach_lock().  Fix this by using IS_ERR_OR_NULL().

Signed-off-by: Richard Weinberger <richard@nod.at>
Cc: Mark Fasheh <mfasheh@suse.com>
Cc: Joel Becker <jlbec@evilplan.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
fs/ocfs2/namei.c