fix: another delete file commit bug

This commit is contained in:
Hongze Cheng 2022-07-07 06:41:05 +00:00
parent 3f2ce5985b
commit 124125677f
1 changed files with 3 additions and 3 deletions

View File

@ -168,8 +168,6 @@ static int32_t tsdbCommitTableDel(SCommitter *pCommitter, STbData *pTbData, SDel
tb_uid_t suid;
tb_uid_t uid;
taosArrayClear(pCommitter->aDelData);
if (pTbData) {
suid = pTbData->suid;
uid = pTbData->uid;
@ -185,6 +183,8 @@ static int32_t tsdbCommitTableDel(SCommitter *pCommitter, STbData *pTbData, SDel
code = tsdbReadDelData(pCommitter->pDelFReader, pDelIdx, pCommitter->aDelData, NULL);
if (code) goto _err;
} else {
taosArrayClear(pCommitter->aDelData);
}
if (pTbData == NULL && pDelIdx == NULL) goto _exit;
@ -205,7 +205,7 @@ static int32_t tsdbCommitTableDel(SCommitter *pCommitter, STbData *pTbData, SDel
if (code) goto _err;
// put delIdx
if (taosArrayPush(pCommitter->aDelIdx, &delIdx) == NULL) {
if (taosArrayPush(pCommitter->aDelIdxN, &delIdx) == NULL) {
code = TSDB_CODE_OUT_OF_MEMORY;
goto _err;
}