diff options
| author | Ben Collins <bcollins@debian.org> | 2003-05-25 19:58:37 -0700 |
|---|---|---|
| committer | Ben Collins <bcollins@debian.org> | 2003-05-25 19:58:37 -0700 |
| commit | 27690cd5f0ca7b96bf49e049f0d0e681878ca83e (patch) | |
| tree | 9573272c4a5f949d1d715a5fde92fd9d8b52b84d /drivers/hotplug | |
| parent | c480493df72e1db86d9a2c740dbb92814ef7ff06 (diff) | |
[PATCH] drivers/* strlcpy conversions
Well, this is it for me and strlcpy. I'll leave the rest of the
non-obvious usages of strncpy to the kernel janitors. Seems like quite a
few uses really wanted memcpy instead, but I don't have time to
investigate them all. It does appear that nearly all strncpy's will be
removable. Obsoleting strncpy will probably atleast make the remaining
few think about how they are using it.
This is the patch for my trip through drivers/*.
Diffstat (limited to 'drivers/hotplug')
| -rw-r--r-- | drivers/hotplug/pci_hotplug_core.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/hotplug/pci_hotplug_core.c b/drivers/hotplug/pci_hotplug_core.c index 8f204a62dfd1..9f51a2d3526d 100644 --- a/drivers/hotplug/pci_hotplug_core.c +++ b/drivers/hotplug/pci_hotplug_core.c @@ -529,7 +529,7 @@ int pci_hp_register (struct hotplug_slot *slot) if ((slot->info == NULL) || (slot->ops == NULL)) return -EINVAL; - strncpy(slot->kobj.name, slot->name, KOBJ_NAME_LEN); + strlcpy(slot->kobj.name, slot->name, KOBJ_NAME_LEN); kobj_set_kset_s(slot, hotplug_slots_subsys); /* this can fail if we have already registered a slot with the same name */ |
