From 835a68409cb230cccd703fe8e5ffcba3a1096c8e Mon Sep 17 00:00:00 2001 From: jow Date: Sun, 19 Sep 2010 15:04:08 +0000 Subject: [package] base-files: cached state vars after scan_interfaces might be out of sync when binding dhcp leases, this could lead to an unconfigured wan interface in certain circumstances. Replace config_get calls with uci_get_state git-svn-id: svn://svn.openwrt.org/openwrt/trunk@23091 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- package/base-files/files/usr/share/udhcpc/default.script | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'package/base-files/files/usr/share') diff --git a/package/base-files/files/usr/share/udhcpc/default.script b/package/base-files/files/usr/share/udhcpc/default.script index 39527778a..92e3474bd 100755 --- a/package/base-files/files/usr/share/udhcpc/default.script +++ b/package/base-files/files/usr/share/udhcpc/default.script @@ -21,9 +21,9 @@ setup_interface () { local user_router [ -n "$ifc" ] && { - config_get old_ip "$ifc" ipaddr - config_get old_broadcast "$ifc" broadcast - config_get old_subnet "$ifc" netmask + old_ip="$(uci_get_state network "$ifc" ipaddr)" + old_broadcast="$(uci_get_state network "$ifc" broadcast)" + old_subnet="$(uci_get_state network "$ifc" netmask)" } [ "$ip" != "$old_ip" ] \ -- cgit v1.2.3