summaryrefslogtreecommitdiff
path: root/data
diff options
context:
space:
mode:
Diffstat (limited to 'data')
-rw-r--r--data/85-nm-unmanaged.rules2
1 files changed, 1 insertions, 1 deletions
diff --git a/data/85-nm-unmanaged.rules b/data/85-nm-unmanaged.rules
index aefab5c461..f8d95097ff 100644
--- a/data/85-nm-unmanaged.rules
+++ b/data/85-nm-unmanaged.rules
@@ -6,7 +6,7 @@ SUBSYSTEM!="net", GOTO="nm_unmanaged_end"
# Determine ID_NET_DRIVER if there's no ID_NET_DRIVER or DRIVERS (old udev?)
ENV{ID_NET_DRIVER}=="?*", GOTO="nm_unmanaged_driver"
DRIVERS=="?*", GOTO="nm_unmanaged_driver"
-PROGRAM="/bin/sh -c '/usr/sbin/ethtool -i $env{INTERFACE} |/bin/sed -n s/^driver:\ //p'", RESULT=="?*", ENV{ID_NET_DRIVER}="%c"
+PROGRAM="/bin/sh -c 'test -e "/sys/class/net/$env{INTERFACE}" && /usr/sbin/ethtool -i "$env{INTERFACE}" | /bin/sed -n s/^driver:\ //p'", RESULT=="?*", ENV{ID_NET_DRIVER}="%c"
LABEL="nm_unmanaged_driver"
# VirtualBox host networking. Out-of-tree driver that looks like an ordinary