diff options
author | Dan Carpenter | 2011-03-14 10:35:31 +0100 |
---|---|---|
committer | Greg Kroah-Hartman | 2011-03-14 19:47:59 +0100 |
commit | e278913c3c70dea6302d99f5f0ee4961e09970b6 (patch) | |
tree | 918f233bbb1ee842ac313de1e5113dc4b39b1e72 /drivers/staging/crystalhd | |
parent | Staging: crystalhd: change GFP_ATOMIC to GFP_KERNEL (diff) | |
download | kernel-qcow2-linux-e278913c3c70dea6302d99f5f0ee4961e09970b6.tar.gz kernel-qcow2-linux-e278913c3c70dea6302d99f5f0ee4961e09970b6.tar.xz kernel-qcow2-linux-e278913c3c70dea6302d99f5f0ee4961e09970b6.zip |
Staging: crystalhd: don't waste the last char of buffer
pinfo->name is a 32 char buffer. In the original code, the last char
wasn't fully utilized.
Signed-off-by: Dan Carpenter <error27@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'drivers/staging/crystalhd')
-rw-r--r-- | drivers/staging/crystalhd/crystalhd_lnx.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/staging/crystalhd/crystalhd_lnx.c b/drivers/staging/crystalhd/crystalhd_lnx.c index 9a6b650cd608..c1ee24c98315 100644 --- a/drivers/staging/crystalhd/crystalhd_lnx.c +++ b/drivers/staging/crystalhd/crystalhd_lnx.c @@ -562,7 +562,7 @@ static int __devinit chd_dec_pci_probe(struct pci_dev *pdev, return rc; } - snprintf(pinfo->name, 31, "crystalhd_pci_e:%d:%d:%d", + snprintf(pinfo->name, sizeof(pinfo->name), "crystalhd_pci_e:%d:%d:%d", pdev->bus->number, PCI_SLOT(pdev->devfn), PCI_FUNC(pdev->devfn)); |