From e83b3fd287c7534956cd820e986158dd2fc748db Mon Sep 17 00:00:00 2001 From: pan <1029559041@qq.com> Date: Sun, 11 Oct 2020 07:50:15 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A2=9E=E5=8A=A0openresty?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- shell/checkPort | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/shell/checkPort b/shell/checkPort index 05acad9..39c2249 100644 --- a/shell/checkPort +++ b/shell/checkPort @@ -2,7 +2,7 @@ # 检查客户端和服务端端口是否存在 #存在返回0否则返回1 source /app/riskenv -if [[ `/app/findPortPid $PORT|wc -l` -eq 1 && `/app/findPortPid $serverPort|wc -l` -eq 1 ]] +if [[ ! -z "`/app/findPortPid $PORT`" && ! -z "`/app/findPortPid $serverPort`" ]] then echo 0 else