summaryrefslogtreecommitdiff
path: root/udev_add.c
diff options
context:
space:
mode:
Diffstat (limited to 'udev_add.c')
-rw-r--r--udev_add.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/udev_add.c b/udev_add.c
index 7e0c57fc63..aa19d874c3 100644
--- a/udev_add.c
+++ b/udev_add.c
@@ -185,8 +185,8 @@ static int create_node(struct udevice *udev, struct sysfs_class_device *class_de
for (i = 1; i <= udev->partitions; i++) {
dev_t part_devt;
- strfieldcpy(partitionname, filename);
- strintcat(partitionname, i);
+ snprintf(partitionname, NAME_SIZE, "%s%d", filename, i);
+ partitionname[NAME_SIZE-1] = '\0';
part_devt = makedev(major(udev->devt), minor(udev->devt)+1);
udev_make_node(udev, partitionname, part_devt, udev->mode, uid, gid);
}