Staging: wlan-ng: fix Correct size given to memset
authorJulia Lawall <julia@diku.dk>
Wed, 9 Dec 2009 19:25:04 +0000 (20:25 +0100)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 23 Dec 2009 19:27:48 +0000 (11:27 -0800)
commit4068fe8b2aa3e12643db0ad5dd4bcf6755a7320f
tree2d31d9b263851df83bb5733e3ee0f453d7755da5
parent488d3749620779ab2668c0dba2962836e51e3cd6
Staging: wlan-ng: fix Correct size given to memset

Memset should be given the size of the structure, not the size of the pointer.

The semantic patch that makes this change is as follows:
(http://coccinelle.lip6.fr/)

// <smpl>
@@
type T;
T *x;
expression E;
@@

memset(x, E, sizeof(
+ *
 x))
// </smpl>

Signed-off-by: Julia Lawall <julia@diku.dk>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/wlan-ng/prism2fw.c