From cf129cacb9185994bc122b81604018f043baf743 Mon Sep 17 00:00:00 2001 From: yihaoDeng Date: Fri, 10 Feb 2023 10:51:25 +0800 Subject: [PATCH] add mutex --- source/dnode/vnode/src/meta/metaTable.c | 3 +++ 1 file changed, 3 insertions(+) diff --git a/source/dnode/vnode/src/meta/metaTable.c b/source/dnode/vnode/src/meta/metaTable.c index e102744f33..7a7bf6412c 100644 --- a/source/dnode/vnode/src/meta/metaTable.c +++ b/source/dnode/vnode/src/meta/metaTable.c @@ -506,7 +506,10 @@ int metaAddIndexToSTable(SMeta *pMeta, int64_t version, SVCreateStbReq *pReq) { metaDestroyTagIdxKey(pTagIdxKey); goto _err; } + + metaWLock(pMeta); tdbTbUpsert(pMeta->pTagIdx, pTagIdxKey, nTagIdxKey, NULL, 0, pMeta->txn); + metaULock(pMeta); metaDestroyTagIdxKey(pTagIdxKey); } -- GitLab