summaryrefslogtreecommitdiff
path: root/udev/udev-event.c
diff options
context:
space:
mode:
authorKay Sievers <kay.sievers@vrfy.org>2008-12-02 01:04:23 +0100
committerKay Sievers <kay.sievers@vrfy.org>2008-12-02 01:04:23 +0100
commite2c9d3c36f9a2519e909c792bb273a34a5310685 (patch)
tree95df55c37acff0d294e378a242f3549c053a8c5d /udev/udev-event.c
parent4894330e26f2e873a5c311c2783d17c16f167bd2 (diff)
fix network interface name swapping
Diffstat (limited to 'udev/udev-event.c')
-rw-r--r--udev/udev-event.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/udev/udev-event.c b/udev/udev-event.c
index 32b45e9bac..bc692392d2 100644
--- a/udev/udev-event.c
+++ b/udev/udev-event.c
@@ -514,7 +514,7 @@ static int rename_netif(struct udev_event *event)
/* wait 30 seconds for our target to become available */
util_strlcpy(ifr.ifr_name, ifr.ifr_newname, IFNAMSIZ);
- util_strlcpy(ifr.ifr_newname, udev_device_get_devnode(dev), IFNAMSIZ);
+ util_strlcpy(ifr.ifr_newname, event->name, IFNAMSIZ);
loop = 30 * 20;
while (loop--) {
err = ioctl(sk, SIOCSIFNAME, &ifr);
@@ -529,7 +529,7 @@ static int rename_netif(struct udev_event *event)
break;
}
dbg(event->udev, "wait for netif '%s' to become free, loop=%i\n",
- udev_device_get_devnode(dev), (30 * 20) - loop);
+ event->name, (30 * 20) - loop);
usleep(1000 * 1000 / 20);
}
}