mirror of
https://dev.iopsys.eu/feed/iopsys.git
synced 2026-02-16 04:49:13 +01:00
inteno-netmode: remove repeater ready flag on public ip
This commit is contained in:
parent
4ce6f49284
commit
fb648dbec9
1 changed files with 7 additions and 1 deletions
|
|
@ -31,6 +31,12 @@ set_disabled() {
|
|||
test_ip() {
|
||||
if [ -n "$(echo $ip | grep -E '^(192\.168|10\.|172\.1[6789]\.|172\.2[0-9]\.|172\.3[01]\.)')" ]; then
|
||||
set_disabled 1
|
||||
[ "$1" -eq "1" ] && {
|
||||
uci set netmode.setup.repeaterready=0
|
||||
uci commit netmode
|
||||
local pid="$(ps | grep wificontro[l] | awk '/repeater/ {print $1}')"
|
||||
[ "$pid" != "" ] && kill $pid
|
||||
}
|
||||
else
|
||||
set_disabled 0
|
||||
fi
|
||||
|
|
@ -38,6 +44,6 @@ test_ip() {
|
|||
|
||||
case "$(uci -q get netmode.setup.curmode)" in
|
||||
repeater*) test_ip ;;
|
||||
*) [ "$(uci -q get netmode.setup.repeaterready)" == "1" ] && test_ip ;;
|
||||
*) [ "$(uci -q get netmode.setup.repeaterready)" == "1" ] && test_ip 1;;
|
||||
esac
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue