mirror of
git://projects.qi-hardware.com/openwrt-xburst.git
synced 2025-01-27 15:11:06 +02:00
[package] ppp: pass "nodefaultroute" if defaultroute is 0, don't unconditionally truncate resolv.conf, thanks cshore
git-svn-id: svn://svn.openwrt.org/openwrt/trunk@21361 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
parent
2efc23f468
commit
a4aaf05453
@ -59,7 +59,7 @@ start_pppd() {
|
|||||||
local defaultroute
|
local defaultroute
|
||||||
config_get_bool defaultroute "$cfg" defaultroute 1
|
config_get_bool defaultroute "$cfg" defaultroute 1
|
||||||
[ "$defaultroute" -eq 1 ] && \
|
[ "$defaultroute" -eq 1 ] && \
|
||||||
defaultroute="defaultroute replacedefaultroute" || defaultroute=""
|
defaultroute="defaultroute replacedefaultroute" || defaultroute="nodefaultroute"
|
||||||
|
|
||||||
local interval="${keepalive##*[, ]}"
|
local interval="${keepalive##*[, ]}"
|
||||||
[ "$interval" != "$keepalive" ] || interval=5
|
[ "$interval" != "$keepalive" ] || interval=5
|
||||||
@ -77,7 +77,9 @@ start_pppd() {
|
|||||||
local peerdns
|
local peerdns
|
||||||
config_get_bool peerdns "$cfg" peerdns $peer_default
|
config_get_bool peerdns "$cfg" peerdns $peer_default
|
||||||
|
|
||||||
echo -n "" > /tmp/resolv.conf.auto
|
if [ "$peerdns" -eq 1 ] || [ ! -e /tmp/resolv.conf.auto ]; then
|
||||||
|
echo -n "" > /tmp/resolv.conf.auto
|
||||||
|
fi
|
||||||
|
|
||||||
[ "$peerdns" -eq 1 ] && {
|
[ "$peerdns" -eq 1 ] && {
|
||||||
peerdns="usepeerdns"
|
peerdns="usepeerdns"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user