[PATCH] uml: fix hostfs stack corruption
authorJeff Dike <jdike@addtoit.com>
Mon, 27 Mar 2006 09:14:41 +0000 (01:14 -0800)
committerLinus Torvalds <torvalds@g5.osdl.org>
Mon, 27 Mar 2006 16:44:39 +0000 (08:44 -0800)
Noted by Oleg Drokin:
We initialized an extra slot of struct kstatfs.spare, sometimes
causing stack corruption.

Signed-off-by: Jeff Dike <jdike@addtoit.com>
Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
Cc: Oleg Drokin <green@clusterfs.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
fs/hostfs/hostfs_user.c

index b97809deba66ce63e2644bf698fdc0ac851fe1bf..23b7cee72123b8489329c5b38c4dbb12aaf25ade 100644 (file)
@@ -360,7 +360,6 @@ int do_statfs(char *root, long *bsize_out, long long *blocks_out,
        spare_out[2] = buf.f_spare[2];
        spare_out[3] = buf.f_spare[3];
        spare_out[4] = buf.f_spare[4];
-       spare_out[5] = buf.f_spare[5];
        return(0);
 }