diff options
author | John W. Linville <linville@tuxdriver.com> | 2011-11-28 20:11:18 +0100 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2011-11-28 20:11:18 +0100 |
commit | 39338b56382ac640614851a80e0bd71994cc664d (patch) | |
tree | c319e23181be286b1d320c29f755a81e5ef61172 /drivers/net/wireless/libertas/ethtool.c | |
parent | net/irda: convert drivers/net/irda/* to use module_platform_driver() (diff) | |
parent | rtlwifi: squash warning in _usb_read_sync (diff) | |
download | linux-39338b56382ac640614851a80e0bd71994cc664d.tar.xz linux-39338b56382ac640614851a80e0bd71994cc664d.zip |
Merge branch 'master' of git://git.kernel.org/pub/scm/linux/kernel/git/linville/wireless-next into for-davem
Diffstat (limited to 'drivers/net/wireless/libertas/ethtool.c')
-rw-r--r-- | drivers/net/wireless/libertas/ethtool.c | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/wireless/libertas/ethtool.c b/drivers/net/wireless/libertas/ethtool.c index 885ddc1c4fed..f955b2d66ed6 100644 --- a/drivers/net/wireless/libertas/ethtool.c +++ b/drivers/net/wireless/libertas/ethtool.c @@ -13,13 +13,14 @@ static void lbs_ethtool_get_drvinfo(struct net_device *dev, { struct lbs_private *priv = dev->ml_priv; - snprintf(info->fw_version, 32, "%u.%u.%u.p%u", + snprintf(info->fw_version, sizeof(info->fw_version), + "%u.%u.%u.p%u", priv->fwrelease >> 24 & 0xff, priv->fwrelease >> 16 & 0xff, priv->fwrelease >> 8 & 0xff, priv->fwrelease & 0xff); - strcpy(info->driver, "libertas"); - strcpy(info->version, lbs_driver_version); + strlcpy(info->driver, "libertas", sizeof(info->driver)); + strlcpy(info->version, lbs_driver_version, sizeof(info->version)); } /* |