- snprintf(partitionname, NAME_SIZE, "%s%d", filename, i);
- partitionname[NAME_SIZE-1] = '\0';
- part_devt = makedev(major(udev->devt), minor(udev->devt)+1);
+ snprintf(partitionname, sizeof(partitionname), "%s%d", filename, i);
+ partitionname[sizeof(partitionname)-1] = '\0';
+ part_devt = makedev(major(udev->devt), minor(udev->devt) + i);