diff options
author | Dan Carpenter <dan.carpenter@oracle.com> | 2013-06-12 14:05:00 -0700 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2013-06-12 16:29:46 -0700 |
commit | 282c4c0ecce9b9ac1b69acae32a4239441601405 (patch) | |
tree | 5c4be94e5dcb31e36ec0dcaf9c3c0045769e7533 /drivers/misc | |
parent | 4fcc712f5c48b1e32cdbf9b9cfba42a27b2e3160 (diff) | |
download | linux-282c4c0ecce9b9ac1b69acae32a4239441601405.tar.gz linux-282c4c0ecce9b9ac1b69acae32a4239441601405.tar.bz2 linux-282c4c0ecce9b9ac1b69acae32a4239441601405.zip |
drivers/misc/sgi-gru/grufile.c: fix info leak in gru_get_config_info()
The "info.fill" array isn't initialized so it can leak uninitialized stack
information to user space.
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Acked-by: Robin Holt <holt@sgi.com>
Acked-by: Dimitri Sivanich <sivanich@sgi.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'drivers/misc')
-rw-r--r-- | drivers/misc/sgi-gru/grufile.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/misc/sgi-gru/grufile.c b/drivers/misc/sgi-gru/grufile.c index 44d273c5e19d..0535d1e0bc78 100644 --- a/drivers/misc/sgi-gru/grufile.c +++ b/drivers/misc/sgi-gru/grufile.c @@ -172,6 +172,7 @@ static long gru_get_config_info(unsigned long arg) nodesperblade = 2; else nodesperblade = 1; + memset(&info, 0, sizeof(info)); info.cpus = num_online_cpus(); info.nodes = num_online_nodes(); info.blades = info.nodes / nodesperblade; |