Commit caf91fb1 authored by Edward Shishkin's avatar Edward Shishkin Committed by James Toy

. Fix up incorrect handling errors reterned by d_obtain_alias.

. Make quilt, checkpatch happy:
  remove comment with "joke not for everyone".

Signed-off-by: Edward Shishkin<edward.shishkin@gmail.com>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
parent d01fcde1
...@@ -56,10 +56,7 @@ struct dentry *get_parent_common(struct inode *child) ...@@ -56,10 +56,7 @@ struct dentry *get_parent_common(struct inode *child)
check_light_weight(parent, child); check_light_weight(parent, child);
reiser4_iget_complete(parent); reiser4_iget_complete(parent);
dentry = d_obtain_alias(parent); dentry = d_obtain_alias(parent);
if (dentry == NULL) { if (!IS_ERR(dentry))
iput(parent);
dentry = ERR_PTR(RETERR(-ENOMEM));
} else
dentry->d_op = &get_super_private(s)->ops.dentry; dentry->d_op = &get_super_private(s)->ops.dentry;
} else if (PTR_ERR(parent) == -ENOENT) } else if (PTR_ERR(parent) == -ENOENT)
dentry = ERR_PTR(RETERR(-ESTALE)); dentry = ERR_PTR(RETERR(-ESTALE));
...@@ -353,11 +350,6 @@ int reiser4_dir_done_common(struct inode *object/* object being deleted */) ...@@ -353,11 +350,6 @@ int reiser4_dir_done_common(struct inode *object/* object being deleted */)
result = reiser4_rem_entry_common(object, &goodby_dots, &entry); result = reiser4_rem_entry_common(object, &goodby_dots, &entry);
reiser4_free_dentry_fsdata(&goodby_dots); reiser4_free_dentry_fsdata(&goodby_dots);
if (unlikely(result != 0 && result != -ENOMEM && result != -ENOENT)) if (unlikely(result != 0 && result != -ENOMEM && result != -ENOENT))
/* only worth a warning
"values of B will give rise to dom!\n"
-- v6src/s2/mv.c:89
*/
warning("nikita-2252", "Cannot remove dot of %lli: %i", warning("nikita-2252", "Cannot remove dot of %lli: %i",
(unsigned long long)get_inode_oid(object), result); (unsigned long long)get_inode_oid(object), result);
return 0; return 0;
......
...@@ -476,10 +476,7 @@ struct dentry *wire_get_common(struct super_block *sb, ...@@ -476,10 +476,7 @@ struct dentry *wire_get_common(struct super_block *sb,
if (!IS_ERR(inode)) { if (!IS_ERR(inode)) {
reiser4_iget_complete(inode); reiser4_iget_complete(inode);
dentry = d_obtain_alias(inode); dentry = d_obtain_alias(inode);
if (dentry == NULL) { if (!IS_ERR(dentry))
iput(inode);
dentry = ERR_PTR(-ENOMEM);
} else
dentry->d_op = &get_super_private(sb)->ops.dentry; dentry->d_op = &get_super_private(sb)->ops.dentry;
} else if (PTR_ERR(inode) == -ENOENT) } else if (PTR_ERR(inode) == -ENOENT)
/* /*
......
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