From ce90d228f970238e9b07ab8dc28affd7132b5be2 Mon Sep 17 00:00:00 2001 From: Minglei Jin Date: Wed, 6 Jul 2022 17:10:08 +0800 Subject: [PATCH] fix: fix win CI crash caused by tmp variable --- source/dnode/vnode/src/tsdb/tsdbCommit.c | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/source/dnode/vnode/src/tsdb/tsdbCommit.c b/source/dnode/vnode/src/tsdb/tsdbCommit.c index c390dfb051..9c0cafd6f2 100644 --- a/source/dnode/vnode/src/tsdb/tsdbCommit.c +++ b/source/dnode/vnode/src/tsdb/tsdbCommit.c @@ -523,7 +523,14 @@ static int32_t tsdbCommitTableMemData(SCommitter *pCommitter, STbDataIter *pIter tsdbTbDataIterNext(pIter); pRow = tsdbTbDataIterGet(pIter); - if (pRow && tsdbKeyCmprFn(&TSDBROW_KEY(pRow), &toKey) >= 0) pRow = NULL; + // if (pRow && tsdbKeyCmprFn(&TSDBROW_KEY(pRow), &toKey) >= 0) pRow = NULL; + // crash on CI, use the block following + if (pRow) { + TSDBKEY key = TSDBROW_KEY(pRow); + if (tsdbKeyCmprFn(&TSDBROW_KEY(pRow), &toKey) >= 0) { + pRow = NULL; + } + } if (pBlockData->nRow >= pCommitter->maxRow * 4 / 5) goto _write_block; continue;