aboutsummaryrefslogtreecommitdiffstats
path: root/package/base-files/files
diff options
context:
space:
mode:
authorJo-Philipp Wich <jow@openwrt.org>2010-09-19 15:04:08 +0000
committerJo-Philipp Wich <jow@openwrt.org>2010-09-19 15:04:08 +0000
commit544919fc1fcb1ba8a8a275bad4ec6dc5e325fe00 (patch)
treea2ac9f0fd9366f51b6183523ae4c795bde418b14 /package/base-files/files
parent45585b87773b056d67c27b3df182038bf4b149ca (diff)
downloadupstream-544919fc1fcb1ba8a8a275bad4ec6dc5e325fe00.tar.gz
upstream-544919fc1fcb1ba8a8a275bad4ec6dc5e325fe00.tar.bz2
upstream-544919fc1fcb1ba8a8a275bad4ec6dc5e325fe00.zip
[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
Diffstat (limited to 'package/base-files/files')
-rwxr-xr-xpackage/base-files/files/usr/share/udhcpc/default.script6
1 files changed, 3 insertions, 3 deletions
diff --git a/package/base-files/files/usr/share/udhcpc/default.script b/package/base-files/files/usr/share/udhcpc/default.script
index 39527778ad..92e3474bdd 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" ] \