From: Martin Mares Date: Sat, 13 Dec 2008 11:42:46 +0000 (+0100) Subject: Slots: use strcpy instead of sprintf. X-Git-Tag: v3.1.0~15 X-Git-Url: http://mj.ucw.cz/gitweb/?a=commitdiff_plain;h=527637ddf3f368c5279f87cf75b90af619383db7;p=pciutils.git Slots: use strcpy instead of sprintf. --- diff --git a/lib/sysfs.c b/lib/sysfs.c index 5949ff1..a204eef 100644 --- a/lib/sysfs.c +++ b/lib/sysfs.c @@ -218,7 +218,7 @@ sysfs_fill_slots(struct pci_dev *d) if (dom == pd->domain && bus == pd->bus && dev == pd->dev && !pd->phy_slot) { pd->phy_slot = pci_malloc(a, strlen(entry->d_name) + 1); - sprintf(pd->phy_slot, "%s", entry->d_name); + strcpy(pd->phy_slot, entry->d_name); } pd->known_fields |= PCI_FILL_PHYS_SLOT; }