diff --git a/src/packages/fff/fff-hoods/Makefile b/src/packages/fff/fff-hoods/Makefile index 885599c..d48e7b2 100644 --- a/src/packages/fff/fff-hoods/Makefile +++ b/src/packages/fff/fff-hoods/Makefile @@ -1,7 +1,7 @@ include $(TOPDIR)/rules.mk PKG_NAME:=fff-hoods -PKG_RELEASE:=12 +PKG_RELEASE:=13 PKG_BUILD_DIR:=$(BUILD_DIR)/$(PKG_NAME) diff --git a/src/packages/fff/fff-hoods/files/usr/sbin/configurehood b/src/packages/fff/fff-hoods/files/usr/sbin/configurehood index 766066a..1df6e2a 100755 --- a/src/packages/fff/fff-hoods/files/usr/sbin/configurehood +++ b/src/packages/fff/fff-hoods/files/usr/sbin/configurehood @@ -38,30 +38,6 @@ hasInternet() { return 1 } -# Hidden AP check - -if [ -s "$hoodfilewww" ] && isGatewayAvailable ; then - needwifi="0" - for radio in $(wifiListRadio); do - freq="$(wifiGetFreq $radio)" - - # Break: wXconfig is up - [ "$(uci get "wireless.w${freq}configap.disabled")" = "0" ] && continue - # Break: No mesh interface - [ "$(uci get "wireless.w${freq}mesh.disabled")" = "0" ] || continue - - # Enable configap - uci set wireless.w${freq}configap.disabled='0' - uci commit wireless - needwifi="1" - done - - if [ "$needwifi" = "1" ]; then - reload_config - sleep 10 - fi -fi - if [ -s "$hoodfilelocal" ]; then # remove webroot hoodfile to prevent offering local hoodfiles to neighbours rm -f "$hoodfilewww" @@ -247,3 +223,26 @@ else echo "We haven't got a file. We do nothing. We try it again in 5 minutes..."; exit 0 fi + +# Hidden AP check +if [ -s "$hoodfilewww" ] && isGatewayAvailable; then + needwifi="0" + for radio in $(wifiListRadio); do + freq="$(wifiGetFreq $radio)" + + # Break: wXconfig is up + [ "$(uci get "wireless.w${freq}configap.disabled")" = "0" ] && continue + # Break: No mesh interface + [ "$(uci get "wireless.w${freq}mesh.disabled")" = "0" ] || continue + + # Enable configap + uci set wireless.w${freq}configap.disabled='0' + uci commit wireless + needwifi="1" + done + + if [ "$needwifi" = "1" ]; then + reload_config + sleep 10 + fi +fi