🎈 Sync 2024-12-21 16:27

This commit is contained in:
github-actions[bot] 2024-12-21 16:27:55 +08:00
parent 1292e436a8
commit 0d8d081cdc
2 changed files with 4 additions and 6 deletions

View File

@ -794,7 +794,7 @@ run_global() {
-DEFAULT_DNS ${AUTO_DNS} -LOCAL_DNS ${LOCAL_DNS:-${AUTO_DNS}} -TUN_DNS ${TUN_DNS} \
-NFTFLAG ${nftflag:-0} \
-NO_LOGIC_LOG ${NO_LOGIC_LOG:-0}
/etc/init.d/dnsmasq restart >/dev/null 2>&1
lua $APP_PATH/helper_dnsmasq.lua logic_restart -LOG 1
else
#Run a copy dnsmasq instance, DNS hijack for that need proxy devices.
GLOBAL_DNSMASQ_PORT=$(get_new_port 11400)
@ -1256,7 +1256,7 @@ start() {
uci -q commit ${CONFIG}
uci -q set dhcp.@dnsmasq[0].dns_redirect='0'
uci -q commit dhcp
/etc/init.d/dnsmasq restart >/dev/null 2>&1
lua $APP_PATH/helper_dnsmasq.lua restart -LOG 0
}
fi
[ "$ENABLED_DEFAULT_ACL" == 1 ] && run_global

View File

@ -102,10 +102,8 @@ function logic_restart(var)
tinsert(dns_table, v)
end
end
if dns_table and #dns_table > 0 then
uci:set_list("dhcp", "@dnsmasq[0]", "server", dns_table)
uci:commit("dhcp")
end
uci:set_list("dhcp", "@dnsmasq[0]", "server", dns_table)
uci:commit("dhcp")
end
sys.call("/etc/init.d/dnsmasq restart >/dev/null 2>&1")
restore_servers()