Skip to content

Commit

Permalink
vfs: use ERR_CAST for err-ptr tossing in lookup_instantiate_filp
Browse files Browse the repository at this point in the history
Replace unclear (struct dentry *) to (struct file *) typecast with ERR_CAST() macro.

Signed-off-by: Konstantin Khlebnikov <[email protected]>
Signed-off-by: Al Viro <[email protected]>
  • Loading branch information
koct9i authored and Al Viro committed Jul 22, 2011
1 parent d769b3c commit 5a9a436
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion fs/open.c
Original file line number Diff line number Diff line change
Expand Up @@ -793,7 +793,7 @@ struct file *lookup_instantiate_filp(struct nameidata *nd, struct dentry *dentry
return nd->intent.open.file;
out_err:
release_open_intent(nd);
nd->intent.open.file = (struct file *)dentry;
nd->intent.open.file = ERR_CAST(dentry);
goto out;
}
EXPORT_SYMBOL_GPL(lookup_instantiate_filp);
Expand Down

0 comments on commit 5a9a436

Please sign in to comment.