From 4736c6621dc4ed4f844949736e598239ccc20c41 Mon Sep 17 00:00:00 2001 From: Shengliang Guan Date: Fri, 25 Sep 2020 16:26:16 +0000 Subject: [PATCH] TD-1418 --- src/sync/src/syncMain.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/sync/src/syncMain.c b/src/sync/src/syncMain.c index 3f57a8b5cd..9b73558ba8 100644 --- a/src/sync/src/syncMain.c +++ b/src/sync/src/syncMain.c @@ -167,6 +167,8 @@ void *syncStart(const SSyncInfo *pInfo) { } } + syncAddNodeRef(pNode); + if (pNode->selfIndex < 0) { sInfo("vgId:%d, this node is not configured", pNode->vgId); terrno = TSDB_CODE_SYN_INVALID_CONFIG; @@ -194,7 +196,6 @@ void *syncStart(const SSyncInfo *pInfo) { } syncAddArbitrator(pNode); - syncAddNodeRef(pNode); taosHashPut(vgIdHash, (const char *)&pNode->vgId, sizeof(int32_t), (char *)(&pNode), sizeof(SSyncNode *)); if (pNode->notifyRole) { -- GitLab