staging/lustre: Unbreak ll_prep_inode iget result check
PATCH 1/1 staging/lustre: Unbreak ll_prep_inode iget result check
From: Oleg Drokin <[email protected]>
commit 020ecc6f3229 ("staging: lustre: llite: Remove IS_ERR tests") managed to break one of the converted checks by losing a dereference causing the condition to be wrong and hence leading
to a crash later on in case of actual error. IS_ERR_OR_NULL(*inode) got converted into !inode.
---
I am not sure where did that patch came from as I cannot see it in either my inbox or in any public mailinglists via google.
drivers/staging/lustre/lustre/llite/llite_lib.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/lustre/lustre/llite/llite_lib.c +1 -1
@@ -1972,7 +1972,7 @@ int ll_prep_inode(struct inode **inode, struct ptlrpc_request *req, *inode =ll_iget (sb,cl_fid_build_ino (&md.body->fid1, sbi->ll_flags &LL_SBI_32BIT_API ), &md); -if (!inode) { +if (!*inode) {#ifdef CONFIG_FS_POSIX_ACL if (md.posix_acl) {posix_acl_release (md.posix_acl);
Signature · 1 line
2.1.0
Greg KH
maintainerQuoted 8 lines · green at linuxhacker.ru
From: Oleg Drokin <[email protected]>
commit
020ecc6f3229("staging: lustre: llite: RemoveIS_ERRtests") managed to break one of the converted checks by losing a dereference causing the condition to be wrong and hence leading
to a crash later on in case of actual error.IS_ERR_OR_NULL(*inode)got converted into !inode.
Quoted 5 lines
Signed-off-by Oleg Drokin <[email protected]>CC Amitoj Kaur Chawla <[email protected]>---
I am not sure where did that patch came from as I cannot see it in either my inbox or in any public mailinglists via google.
My fault, it is part of the Outreachy application process, I missed that bug, sorry about this.
greg k-h