diff options
Diffstat (limited to 'udev-add.c')
-rw-r--r-- | udev-add.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/udev-add.c b/udev-add.c index 9562cb5dbb..de1fb953c4 100644 --- a/udev-add.c +++ b/udev-add.c @@ -195,7 +195,8 @@ static int create_node(struct udevice *dev, int fake) gid_t gid = 0; int i; int tail; - int pos, len; + char *pos; + int len; strfieldcpy(filename, udev_root); strfieldcat(filename, dev->name); @@ -281,7 +282,7 @@ static int create_node(struct udevice *dev, int fake) /* create symlink if requested */ foreach_strpart(dev->symlink, " ", pos, len) { - strnfieldcpy(linkname, dev->symlink + pos, len+1); + strnfieldcpy(linkname, pos, len+1); strfieldcpy(filename, udev_root); strfieldcat(filename, linkname); dbg("symlink '%s' to node '%s' requested", filename, dev->name); |