linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [patch 07/12] seq_file: return a negative error code when seq_path_root() fails.
@ 2009-08-06 23:10 akpm
  0 siblings, 0 replies; only message in thread
From: akpm @ 2009-08-06 23:10 UTC (permalink / raw)
  To: viro; +Cc: linux-fsdevel, akpm, penguin-kernel, penguin-kernel

From: Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>

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>
---

 fs/seq_file.c |    1 +
 1 file changed, 1 insertion(+)

diff -puN fs/seq_file.c~seq_file-return-a-negative-error-code-when-seq_path_root-fails fs/seq_file.c
--- a/fs/seq_file.c~seq_file-return-a-negative-error-code-when-seq_path_root-fails
+++ a/fs/seq_file.c
@@ -470,6 +470,7 @@ int seq_path_root(struct seq_file *m, st
 				m->count = s - m->buf;
 				return 0;
 			}
+			err = -ENAMETOOLONG;
 		}
 	}
 	m->count = m->size;
_

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2009-08-06 23:18 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2009-08-06 23:10 [patch 07/12] seq_file: return a negative error code when seq_path_root() fails akpm

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).