summaryrefslogtreecommitdiff
path: root/network
diff options
context:
space:
mode:
authorAaron Griffin <aaronmgriffin@gmail.com>2009-10-05 14:43:35 -0700
committerAaron Griffin <aaronmgriffin@gmail.com>2009-10-05 14:46:59 -0700
commit743745339502da513cce7acbc9b67fbce4378091 (patch)
tree3e38344d2014fe30cbce962453af8385c34e094b /network
parent35a0950d0bc08061e6a27837ec26d4dace04993f (diff)
network: support early 'up' for dhcp interfaces
Previous commit acac4f47597320f55995bdaf692d6f2335a1d67e attempted to parse the name of the interface from the config line, but neglected to check for "dhcp" config lines, in which case the interface is the name Signed-off-by: Aaron Griffin <aaronmgriffin@gmail.com>
Diffstat (limited to 'network')
-rwxr-xr-xnetwork7
1 files changed, 6 insertions, 1 deletions
diff --git a/network b/network
index de144a2..d23b3a9 100755
--- a/network
+++ b/network
@@ -22,7 +22,12 @@ ifup()
eval ifcfg="\$${1}"
# Get the name of the interface from the first token in the string
- ifname=${ifcfg%% *}
+
+ if [ "$ifcfg" = "dhcp" ]; then
+ ifname="$1"
+ else
+ ifname=${ifcfg%% *}
+ fi
/sbin/ifconfig $ifname up