From 77b20bf138369b5ffef40c1f1a094771329950c7 Mon Sep 17 00:00:00 2001 From: Jeff Tao Date: Wed, 6 Nov 2019 08:49:40 +0800 Subject: [PATCH] fix issue 677 --- src/rpc/src/trpc.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/rpc/src/trpc.c b/src/rpc/src/trpc.c index bc27e7290a..a91ce7a213 100644 --- a/src/rpc/src/trpc.c +++ b/src/rpc/src/trpc.c @@ -536,7 +536,9 @@ int taosGetRpcConn(int chann, int sid, char *meterId, STaosRpc *pServer, SRpcCon if (pServer->afp) { int ret = (*pServer->afp)(meterId, &pConn->spi, &pConn->encrypt, pConn->secret, pConn->ckey); if (ret != 0) { - tTrace("%s cid:%d sid:%d id:%s, meterId not there pConn:%p", pServer->label, chann, sid, pConn->meterId, pConn); + tWarn("%s cid:%d sid:%d id:%s, meterId not there pConn:%p", pServer->label, chann, sid, pConn->meterId, pConn); + taosFreeId(pChann->idPool, sid); // sid shall be released + memset(pConn, 0, sizeof(SRpcConn)); return ret; } } -- GitLab