Skip to content

Commit

Permalink
Staging: otus: fix strcpy() overflow
Browse files Browse the repository at this point in the history
wrq->name is only 16 characters long but "IEEE 802.11-MIMO" is 16
characters + a NULL character, so it's too long.  This patch changes it
to "IEEE 802.11abgn".

Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
  • Loading branch information
Dan Carpenter authored and Greg Kroah-Hartman committed Jun 18, 2010
1 parent 84f8008 commit cc7e7d3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/staging/otus/ioctl.c
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@ int usbdrvwext_giwname(struct net_device *dev,
{
/* struct usbdrv_private *macp = dev->ml_priv; */

strcpy(wrq->name, "IEEE 802.11-MIMO");
strcpy(wrq->name, "IEEE 802.11abgn");

return 0;
}
Expand Down

0 comments on commit cc7e7d3

Please sign in to comment.