summaryrefslogtreecommitdiffstats
path: root/openwrt/target/default/target_skeleton/sbin/ifup
diff options
context:
space:
mode:
Diffstat (limited to 'openwrt/target/default/target_skeleton/sbin/ifup')
-rwxr-xr-xopenwrt/target/default/target_skeleton/sbin/ifup3
1 files changed, 2 insertions, 1 deletions
diff --git a/openwrt/target/default/target_skeleton/sbin/ifup b/openwrt/target/default/target_skeleton/sbin/ifup
index 72efa6901..4236de06b 100755
--- a/openwrt/target/default/target_skeleton/sbin/ifup
+++ b/openwrt/target/default/target_skeleton/sbin/ifup
@@ -45,11 +45,12 @@
} done
;;
dhcp)
+ ip=$(nvram get ${type}_ipaddr)
pidfile=/tmp/dhcp-${type}.pid
if [ -f $pidfile ]; then
$DEBUG kill $(cat $pidfile)
fi
- ${DEBUG:-eval} "udhcpc -i $if -b -p $pidfile &"
+ ${DEBUG:-eval} "udhcpc -i $if ${ip:+-r $ip} -b -p $pidfile &"
;;
pppoe)
# handled by /etc/init.d/S50pppoe