mirror of
https://github.com/systemd/systemd.git
synced 2025-01-11 09:18:07 +03:00
[PATCH] fix up printf-like functionality due to previous changes.
This commit is contained in:
parent
98b88dbf70
commit
7408a7fbb5
@ -601,10 +601,6 @@ label_found:
|
||||
continue;
|
||||
|
||||
strcpy(udev->name, dev->name);
|
||||
if (isdigit(class_dev->path[strlen(class_dev->path)-1])) {
|
||||
temp = &class_dev->path[strlen(class_dev->path)-1];
|
||||
strcat(udev->name, temp);
|
||||
}
|
||||
if (dev->mode != 0) {
|
||||
udev->mode = dev->mode;
|
||||
strcpy(udev->owner, dev->owner);
|
||||
@ -819,7 +815,9 @@ static int get_attr(struct sysfs_class_device *class_dev, struct udevice *udev)
|
||||
done:
|
||||
/* substitute placeholder in NAME */
|
||||
while (1) {
|
||||
pos = strchr(udev->name, '%');
|
||||
char *pos = strchr(udev->name, '%');
|
||||
char *dig;
|
||||
char name[NAME_SIZE];
|
||||
if (pos) {
|
||||
strcpy(name, pos+2);
|
||||
*pos = 0x00;
|
||||
|
Loading…
Reference in New Issue
Block a user