Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 7a62cc10 authored by Tetsuo Handa's avatar Tetsuo Handa Committed by Al Viro
Browse files

seq_file: return a negative error code when seq_path_root() fails.



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: default avatarTetsuo Handa <penguin-kernel@I-love.SAKURA.ne.jp>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarAl Viro <viro@zeniv.linux.org.uk>
parent ce06e0b2
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -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;