diff --git a/src/mnode/src/mnodeShow.c b/src/mnode/src/mnodeShow.c index e3d5b41be317272501bf84607f41adb50c43fbd6..1d85a8cacd92cc2b9f33c36828308edf764d4aef 100644 --- a/src/mnode/src/mnodeShow.c +++ b/src/mnode/src/mnodeShow.c @@ -236,7 +236,7 @@ static int32_t mnodeProcessHeartBeatMsg(SMnodeMsg *pMsg) { } SCMHeartBeatMsg *pHBMsg = pMsg->rpcMsg.pCont; - SRpcConnInfo connInfo; + SRpcConnInfo connInfo = {0}; rpcGetConnInfo(pMsg->rpcMsg.handle, &connInfo); int32_t connId = htonl(pHBMsg->connId); @@ -284,7 +284,7 @@ static int32_t mnodeProcessConnectMsg(SMnodeMsg *pMsg) { SCMConnectRsp *pConnectRsp = NULL; int32_t code = TSDB_CODE_SUCCESS; - SRpcConnInfo connInfo; + SRpcConnInfo connInfo = {0}; if (rpcGetConnInfo(pMsg->rpcMsg.handle, &connInfo) != 0) { mError("thandle:%p is already released while process connect msg", pMsg->rpcMsg.handle); code = TSDB_CODE_MND_INVALID_CONNECTION; diff --git a/src/mnode/src/mnodeUser.c b/src/mnode/src/mnodeUser.c index 84f5d6aa58403ca887c9a6be6d52fad5ad63be1d..8c783eebaf64fe377b9756e26196573c8fdfcaca 100644 --- a/src/mnode/src/mnodeUser.c +++ b/src/mnode/src/mnodeUser.c @@ -358,7 +358,7 @@ static int32_t mnodeRetrieveUsers(SShowObj *pShow, char *data, int32_t rows, voi } SUserObj *mnodeGetUserFromConn(void *pConn) { - SRpcConnInfo connInfo; + SRpcConnInfo connInfo = {0}; if (rpcGetConnInfo(pConn, &connInfo) == 0) { return mnodeGetUser(connInfo.user); } else {