X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;ds=sidebyside;f=udev-add.c;h=900e4795aa0d5bc977be9d88427ad781061fd34f;hb=a41de03083de75a972ee48dbe2c8c03f5d73cf57;hp=5dc46cf2a71ecf87d15512b475b29fab9e293a19;hpb=49747bdc374d6f98846e86d57016d8009aacb1cb;p=elogind.git diff --git a/udev-add.c b/udev-add.c index 5dc46cf2a..900e4795a 100644 --- a/udev-add.c +++ b/udev-add.c @@ -453,6 +453,7 @@ int udev_add_device(char *path, char *subsystem, int fake) break; case 'n': + strfieldcpy(devpath, path); if (strcmp(dev.name, dev.kernel_name) != 0) { retval = rename_net_if(&dev, fake); if (retval != 0) @@ -460,7 +461,6 @@ int udev_add_device(char *path, char *subsystem, int fake) /* netif's are keyed with the configured name, cause * the original kernel name sleeps with the fishes */ - strfieldcpy(devpath, path); pos = strrchr(devpath, '/'); if (pos != NULL) { pos[1] = '\0';