From f93bd44f97cbaa645dbbf6705eafa83e76b62d28 Mon Sep 17 00:00:00 2001 From: dapan1121 Date: Wed, 15 Jun 2022 20:29:39 +0800 Subject: [PATCH] fix ut issue and crash issue --- source/dnode/mnode/impl/src/mndProfile.c | 1 - source/dnode/mnode/impl/test/profile/profile.cpp | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/source/dnode/mnode/impl/src/mndProfile.c b/source/dnode/mnode/impl/src/mndProfile.c index ba09a182bb..20d94e341c 100644 --- a/source/dnode/mnode/impl/src/mndProfile.c +++ b/source/dnode/mnode/impl/src/mndProfile.c @@ -359,7 +359,6 @@ static int32_t mndProcessQueryHeartBeat(SMnode *pMnode, SRpcMsg *pMsg, SClientHb return -1; } else { mDebug("user:%s, conn:%u is freed and create a new conn:%u", connInfo.user, pBasic->connId, pConn->id); - pConn = mndAcquireConn(pMnode, pBasic->connId); } } diff --git a/source/dnode/mnode/impl/test/profile/profile.cpp b/source/dnode/mnode/impl/test/profile/profile.cpp index 794374a91d..039700ae9e 100644 --- a/source/dnode/mnode/impl/test/profile/profile.cpp +++ b/source/dnode/mnode/impl/test/profile/profile.cpp @@ -88,7 +88,7 @@ TEST_F(MndTestProfile, 02_ConnectMsg_InvalidDB) { TEST_F(MndTestProfile, 03_ConnectMsg_Show) { test.SendShowReq(TSDB_MGMT_TABLE_CONNS, "connections", ""); - EXPECT_EQ(test.GetShowRows(), 0); + EXPECT_EQ(test.GetShowRows(), 1); } TEST_F(MndTestProfile, 04_HeartBeatMsg) { -- GitLab