From: Felix Fietkau Date: Fri, 7 Sep 2007 13:09:17 +0000 (+0000) Subject: fix ppp unit number issues (#2178) X-Git-Tag: 8.09_rc1~2790 X-Git-Url: http://git.lede-project.org./?a=commitdiff_plain;h=469c6588985c280078952448876ebc6bf0e640af;p=openwrt%2Fsvn-archive%2Fopenwrt.git fix ppp unit number issues (#2178) SVN-Revision: 8665 --- diff --git a/package/ppp/files/ppp.sh b/package/ppp/files/ppp.sh index 9f50e85ef2..5ca1cf9c7d 100644 --- a/package/ppp/files/ppp.sh +++ b/package/ppp/files/ppp.sh @@ -1,9 +1,12 @@ scan_ppp() { config_get ifname "$1" ifname pppdev="${pppdev:-0}" - config_set "$1" ifname "ppp$pppdev" - config_set "$1" unit "$pppdev" - pppdev="$(($pppdev + 1))" + config_get unit "$1" unit + [ -z "$unit" ] && { + config_set "$1" ifname "ppp$pppdev" + config_set "$1" unit "$pppdev" + pppdev="$(($pppdev + 1))" + } } start_pppd() {