diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-06-19 04:35:42 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-06-19 04:37:57 -0400 |
commit | c9036e9f3b2b77f678572260e1ef1075fcb08c36 (patch) | |
tree | e8066f53765329d0e4a2466847b4aac68fda85b9 /arch | |
parent | 8177a9d79c0e942dcac3312f15585d0344d505a5 (diff) |
mconsole: we'd better initialize pos before passing it to vfs_read()...
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/um/drivers/mconsole_kern.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/arch/um/drivers/mconsole_kern.c b/arch/um/drivers/mconsole_kern.c index d7d21851e60c..3df3bd544492 100644 --- a/arch/um/drivers/mconsole_kern.c +++ b/arch/um/drivers/mconsole_kern.c | |||
@@ -147,7 +147,7 @@ void mconsole_proc(struct mc_request *req) | |||
147 | } | 147 | } |
148 | 148 | ||
149 | do { | 149 | do { |
150 | loff_t pos; | 150 | loff_t pos = file->f_pos; |
151 | mm_segment_t old_fs = get_fs(); | 151 | mm_segment_t old_fs = get_fs(); |
152 | set_fs(KERNEL_DS); | 152 | set_fs(KERNEL_DS); |
153 | len = vfs_read(file, buf, PAGE_SIZE - 1, &pos); | 153 | len = vfs_read(file, buf, PAGE_SIZE - 1, &pos); |