From b531944f03829c31903d746f89d6ae7a5a5a672e Mon Sep 17 00:00:00 2001 From: Jeff Tao Date: Fri, 19 Jun 2020 11:29:02 +0000 Subject: [PATCH] set pRpc --- src/rpc/src/rpcMain.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/rpc/src/rpcMain.c b/src/rpc/src/rpcMain.c index 69db734588..3f183ef15f 100644 --- a/src/rpc/src/rpcMain.c +++ b/src/rpc/src/rpcMain.c @@ -579,14 +579,15 @@ static void rpcReleaseConn(SRpcConn *pConn) { rpcFreeMsg(pConn->pRspMsg); // it may have a response msg saved, but not request msg } + tTrace("%s, rpc connection is released", pConn->info); + // lockedBy can not be reset, since it maybe hold by a thread int sid = pConn->sid; int64_t lockedBy = pConn->lockedBy; memset(pConn, 0, sizeof(SRpcConn)); pConn->lockedBy = lockedBy; + pConn->pRpc = pRpc; taosFreeId(pRpc->idPool, sid); - - tTrace("%s, rpc connection is released", pConn->info); } static void rpcCloseConn(void *thandle) {