From 3ec1f3c10e517d7012956604c3b88ee9ebd8fa78 Mon Sep 17 00:00:00 2001 From: Cary Xu Date: Fri, 17 Sep 2021 10:24:20 +0800 Subject: [PATCH] update --- src/tsdb/inc/tsdbMeta.h | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/src/tsdb/inc/tsdbMeta.h b/src/tsdb/inc/tsdbMeta.h index 5bf36aad80..6e50a4de79 100644 --- a/src/tsdb/inc/tsdbMeta.h +++ b/src/tsdb/inc/tsdbMeta.h @@ -110,9 +110,8 @@ static FORCE_INLINE STSchema* tsdbGetTableSchemaImpl(STable* pTable, bool lock, } else { // get the schema with version void* ptr = taosArraySearch(pDTable->schema, &_version, tsdbCompareSchemaVersion, TD_EQ); if (ptr == NULL) { - pTSchema = *(STSchema**)taosArrayGetLast(pDTable->schema); - // terrno = TSDB_CODE_TDB_IVD_TB_SCHEMA_VERSION; - // goto _exit; + terrno = TSDB_CODE_TDB_IVD_TB_SCHEMA_VERSION; + goto _exit; } else { pTSchema = *(STSchema**)ptr; } @@ -126,7 +125,7 @@ static FORCE_INLINE STSchema* tsdbGetTableSchemaImpl(STable* pTable, bool lock, pSchema = pTSchema; } - // _exit: +_exit: if (lock) TSDB_RUNLOCK_TABLE(pDTable); return pSchema; } -- GitLab