aboutsummaryrefslogtreecommitdiffstats
path: root/fs/9p/trans_fd.c
diff options
context:
space:
mode:
authorLatchesar Ionkov <lucho@advancedsolutions.com>2006-03-08 00:55:42 -0500
committerLinus Torvalds <torvalds@g5.osdl.org>2006-03-08 17:14:02 -0500
commit731805b49489055c1548f7ccfbd44c9b84013264 (patch)
tree8ff2ee8091a911a6dfb15e02bfcb61d7a9af46b7 /fs/9p/trans_fd.c
parented2da193fe6671fe4d7e34041bae40308d18247f (diff)
[PATCH] v9fs: fix for access to unitialized variables or freed memory
Miscellaneous fixes related to accessing uninitialized variables or memory that was already freed. Signed-off-by: Latchesar Ionkov <lucho@ionkov.net> Cc: Eric Van Hensbergen <ericvh@ericvh.myip.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
Diffstat (limited to 'fs/9p/trans_fd.c')
-rw-r--r--fs/9p/trans_fd.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/9p/trans_fd.c b/fs/9p/trans_fd.c
index 1a28ef97a3d1..5b2ce21b10fa 100644
--- a/fs/9p/trans_fd.c
+++ b/fs/9p/trans_fd.c
@@ -80,6 +80,7 @@ static int v9fs_fd_send(struct v9fs_transport *trans, void *v, int len)
80 if (!trans || trans->status != Connected || !ts) 80 if (!trans || trans->status != Connected || !ts)
81 return -EIO; 81 return -EIO;
82 82
83 oldfs = get_fs();
83 set_fs(get_ds()); 84 set_fs(get_ds());
84 /* The cast to a user pointer is valid due to the set_fs() */ 85 /* The cast to a user pointer is valid due to the set_fs() */
85 ret = vfs_write(ts->out_file, (void __user *)v, len, &ts->out_file->f_pos); 86 ret = vfs_write(ts->out_file, (void __user *)v, len, &ts->out_file->f_pos);