diff options
Diffstat (limited to 'sysconfig/network-scripts/ifdown')
-rwxr-xr-x | sysconfig/network-scripts/ifdown | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sysconfig/network-scripts/ifdown b/sysconfig/network-scripts/ifdown index c16f251f..6f1be524 100755 --- a/sysconfig/network-scripts/ifdown +++ b/sysconfig/network-scripts/ifdown @@ -5,6 +5,9 @@ cd /etc/sysconfig/network-scripts . network-functions +[ -f ../network ] && . ../network +[ -f ../networking/network ] && . ../networking/network + CONFIG=$1 [ -z "$CONFIG" ] && { @@ -21,8 +24,9 @@ need_config $CONFIG if [ $UID != 0 ]; then if [ -x /usr/sbin/usernetctl ]; then - if /usr/sbin/usernetctl $CONFIG report ; then - exec /usr/sbin/usernetctl $CONFIG down + source_config + if /usr/sbin/usernetctl ${DEVICE} report ; then + exec /usr/sbin/usernetctl ${DEVICE} down fi fi echo $"Users cannot control this device." >&2 |