diff options
author | Dmitry V. Levin <ldv@altlinux.org> | 2015-03-19 11:10:54 +0000 |
---|---|---|
committer | Sasha Levin <sasha.levin@oracle.com> | 2016-04-18 08:51:00 -0400 |
commit | 452718f54822d63ffff0aebb713c5ccd722fd050 (patch) | |
tree | 688e2c5f5cbd812416759c9e38594a73381e698d /fs | |
parent | 03d44e3d9dd7744fe97ca472fce1725b7179fa2f (diff) | |
download | lwn-452718f54822d63ffff0aebb713c5ccd722fd050.tar.gz lwn-452718f54822d63ffff0aebb713c5ccd722fd050.zip |
vfs: show_vfsstat: do not ignore errors from show_devname method
[ Upstream commit 5f8d498d4364f544fee17125787a47553db02afa ]
Explicitly check show_devname method return code and bail out in case
of an error. This fixes regression introduced by commit 9d4d65748a5c.
Cc: stable@vger.kernel.org
Signed-off-by: Dmitry V. Levin <ldv@altlinux.org>
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Sasha Levin <sasha.levin@oracle.com>
Diffstat (limited to 'fs')
-rw-r--r-- | fs/proc_namespace.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/fs/proc_namespace.c b/fs/proc_namespace.c index 8db932da4009..a5644c41a182 100644 --- a/fs/proc_namespace.c +++ b/fs/proc_namespace.c @@ -196,6 +196,8 @@ static int show_vfsstat(struct seq_file *m, struct vfsmount *mnt) if (sb->s_op->show_devname) { seq_puts(m, "device "); err = sb->s_op->show_devname(m, mnt_path.dentry); + if (err) + goto out; } else { if (r->mnt_devname) { seq_puts(m, "device "); |