Commit 642c937b authored by Al Viro's avatar Al Viro

ufs should use d_splice_alias()

it's NFS-exportable, so...
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent a803b806
...@@ -56,16 +56,12 @@ static struct dentry *ufs_lookup(struct inode * dir, struct dentry *dentry, stru ...@@ -56,16 +56,12 @@ static struct dentry *ufs_lookup(struct inode * dir, struct dentry *dentry, stru
lock_ufs(dir->i_sb); lock_ufs(dir->i_sb);
ino = ufs_inode_by_name(dir, &dentry->d_name); ino = ufs_inode_by_name(dir, &dentry->d_name);
if (ino) { if (ino)
inode = ufs_iget(dir->i_sb, ino); inode = ufs_iget(dir->i_sb, ino);
if (IS_ERR(inode)) {
unlock_ufs(dir->i_sb);
return ERR_CAST(inode);
}
}
unlock_ufs(dir->i_sb); unlock_ufs(dir->i_sb);
d_add(dentry, inode); if (IS_ERR(inode))
return NULL; return ERR_CAST(inode);
return d_splice_alias(inode, dentry);
} }
/* /*
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment