From 8af4e1f289a09fa3b0956342ed9e484d2717f84e Mon Sep 17 00:00:00 2001 From: Hyy2001X <1804430051@qq.com> Date: Sun, 7 Nov 2021 10:19:58 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=BD=AC=E4=B9=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Scripts/AutoBuild_Function.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Scripts/AutoBuild_Function.sh b/Scripts/AutoBuild_Function.sh index c7eb16e..164ef2b 100755 --- a/Scripts/AutoBuild_Function.sh +++ b/Scripts/AutoBuild_Function.sh @@ -145,7 +145,7 @@ sed -i 's/services/vpn/g' /usr/lib/lua/luci/view/v2ray_server/users_list_status. sed -i 's/services/vpn/g' /usr/lib/lua/luci/view/v2ray_server/users_list_status.htm sed -i 's/services/vpn/g' /usr/lib/lua/luci/view/v2ray_server/v2ray.htm -if [ -z "$(grep "REDIRECT --to-ports 53" /etc/firewall.user)" ] +if [ -z "\$(grep "REDIRECT --to-ports 53" /etc/firewall.user 2> /dev/null)" ] then echo '#iptables -t nat -A PREROUTING -p udp --dport 53 -j REDIRECT --to-ports 53' >> /etc/firewall.user echo '#iptables -t nat -A PREROUTING -p tcp --dport 53 -j REDIRECT --to-ports 53' >> /etc/firewall.user @@ -468,4 +468,4 @@ Copy() { cp -a $1 $2/$3 fi [[ $? == 0 ]] && ECHO "Done." || ECHO "Failed." -} \ No newline at end of file +}