diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2011-07-08 21:20:11 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2011-07-20 01:44:26 -0400 |
commit | a9049376ee05bf966bfe2b081b5071326856890a (patch) | |
tree | efb3cbfc7760537f201bb28dacbb0d39ec39f04c /fs/ext3 | |
parent | 0c1aa9a952c3608eb17bf990466f1491d1ee8b6c (diff) |
make d_splice_alias(ERR_PTR(err), dentry) = ERR_PTR(err)
... and simplify the living hell out of callers
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ext3')
-rw-r--r-- | fs/ext3/namei.c | 14 |
1 files changed, 5 insertions, 9 deletions
diff --git a/fs/ext3/namei.c b/fs/ext3/namei.c index 34b6d9bfc48a..c095cf5640c7 100644 --- a/fs/ext3/namei.c +++ b/fs/ext3/namei.c | |||
@@ -1038,15 +1038,11 @@ static struct dentry *ext3_lookup(struct inode * dir, struct dentry *dentry, str | |||
1038 | return ERR_PTR(-EIO); | 1038 | return ERR_PTR(-EIO); |
1039 | } | 1039 | } |
1040 | inode = ext3_iget(dir->i_sb, ino); | 1040 | inode = ext3_iget(dir->i_sb, ino); |
1041 | if (IS_ERR(inode)) { | 1041 | if (inode == ERR_PTR(-ESTALE)) { |
1042 | if (PTR_ERR(inode) == -ESTALE) { | 1042 | ext3_error(dir->i_sb, __func__, |
1043 | ext3_error(dir->i_sb, __func__, | 1043 | "deleted inode referenced: %lu", |
1044 | "deleted inode referenced: %lu", | 1044 | ino); |
1045 | ino); | 1045 | return ERR_PTR(-EIO); |
1046 | return ERR_PTR(-EIO); | ||
1047 | } else { | ||
1048 | return ERR_CAST(inode); | ||
1049 | } | ||
1050 | } | 1046 | } |
1051 | } | 1047 | } |
1052 | return d_splice_alias(inode, dentry); | 1048 | return d_splice_alias(inode, dentry); |