Skip to content

Commit

Permalink
seq_file: return a negative error code when seq_path_root() fails.
Browse files Browse the repository at this point in the history
seq_path_root() is returning a return value of successful __d_path()
instead of returning a negative value when mangle_path() failed.

This is not a bug so far because nobody is using return value of
seq_path_root().

Signed-off-by: Tetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
  • Loading branch information
Tetsuo Handa authored and Al Viro committed Sep 24, 2009
1 parent ce06e0b commit 7a62cc1
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions fs/seq_file.c
Original file line number Diff line number Diff line change
Expand Up @@ -470,6 +470,7 @@ int seq_path_root(struct seq_file *m, struct path *path, struct path *root,
m->count = s - m->buf;
return 0;
}
err = -ENAMETOOLONG;
}
}
m->count = m->size;
Expand Down

0 comments on commit 7a62cc1

Please sign in to comment.