From: Travis Kemen Date: Tue, 2 Sep 2008 01:37:06 +0000 (+0000) Subject: add option to cache local queries, from sn9 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=347913a53c61cfcf0e5222fdbb735df9c4039aa3;p=openwrt%2Fstaging%2Fldir.git add option to cache local queries, from sn9 SVN-Revision: 12485 --- diff --git a/package/dnsmasq/files/dnsmasq.init b/package/dnsmasq/files/dnsmasq.init index 60ffc8c7aa..79e57d5f3c 100644 --- a/package/dnsmasq/files/dnsmasq.init +++ b/package/dnsmasq/files/dnsmasq.init @@ -66,6 +66,7 @@ dnsmasq() { config_get leasefile $cfg leasefile [ -e "$leasefile" ] || touch "$leasefile" + config_get_bool cachelocal "$cfg" cachelocal 1 } dhcp_subscrid_add() { @@ -202,7 +203,7 @@ dhcp_add() { [ -n "$ifname" ] || return 0 config_get dnsserver "$net" dns - [ -n "$dnsserver" ] && { + [ "$cachelocal" = "0" -a -n "$dnsserver" ] && { DNS_SERVERS="$DNS_SERVERS $dnsserver" }