Staging: rtl8712: fix math errors in snprintf()
authorDan Carpenter <error27@gmail.com>
Tue, 8 Feb 2011 22:45:13 +0000 (01:45 +0300)
committerGreg Kroah-Hartman <gregkh@suse.de>
Wed, 9 Feb 2011 19:51:27 +0000 (11:51 -0800)
commitd936435f2082788748ae5783cf2c006367d04bb8
treeaaebcffaaf93b2bfc46da131e2ae283f4ea9fdb0
parentec42dc2c7f6a530d16562a061cb3d00a63f8a612
Staging: rtl8712: fix math errors in snprintf()

The original code had calls to snprintf(p, 7, "wpa_ie=") but that string
is 8 characters (because snprintf() puts a NUL terminator on the end).
So instead of an '=' the what gets written to buf is a NUL terminator
followed by the rest of the string.

And actually the %02x formats are three chars as well when you include
the terminator.

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
drivers/staging/rtl8712/rtl871x_ioctl_linux.c