summaryrefslogtreecommitdiffstats
path: root/drivers/net/ethernet/sis/sis190.c
diff options
context:
space:
mode:
authorRick Jones <rick.jones2@hp.com>2011-11-09 09:58:07 +0000
committerDavid S. Miller <davem@davemloft.net>2011-11-14 00:35:46 -0500
commit23020ab35364f2c91133b099c2b1f7458e29aa96 (patch)
tree838cf53bb3b1670f591d404db40b5fe22b8c52fb /drivers/net/ethernet/sis/sis190.c
parent952c5ca14eab113072716ae075c6fd184f011a89 (diff)
downloadlinux-23020ab35364f2c91133b099c2b1f7458e29aa96.tar.gz
linux-23020ab35364f2c91133b099c2b1f7458e29aa96.tar.bz2
linux-23020ab35364f2c91133b099c2b1f7458e29aa96.zip
Sweep additional floors of strcpy in .get_drvinfo routines
Perform another round of floor sweeping, converting the .get_drvinfo routines of additional drivers from strcpy to strlcpy along with some conversion of sprintf to snprintf. Signed-off-by: Rick Jones <rick.jones2@hp.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/sis/sis190.c')
-rw-r--r--drivers/net/ethernet/sis/sis190.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/drivers/net/ethernet/sis/sis190.c b/drivers/net/ethernet/sis/sis190.c
index 1b4658c99391..220e98219a3b 100644
--- a/drivers/net/ethernet/sis/sis190.c
+++ b/drivers/net/ethernet/sis/sis190.c
@@ -1760,9 +1760,10 @@ static void sis190_get_drvinfo(struct net_device *dev,
{
struct sis190_private *tp = netdev_priv(dev);
- strcpy(info->driver, DRV_NAME);
- strcpy(info->version, DRV_VERSION);
- strcpy(info->bus_info, pci_name(tp->pci_dev));
+ strlcpy(info->driver, DRV_NAME, sizeof(info->driver));
+ strlcpy(info->version, DRV_VERSION, sizeof(info->version));
+ strlcpy(info->bus_info, pci_name(tp->pci_dev),
+ sizeof(info->bus_info));
}
static int sis190_get_regs_len(struct net_device *dev)