fix:review

This commit is contained in:
pengrongkun94@qq.com 2025-02-28 16:16:15 +08:00
parent d4656efcb1
commit 703a9924a4
1 changed files with 5 additions and 5 deletions

View File

@ -328,7 +328,7 @@ int32_t qBindStmtStbColsValue(void* pBlock, SArray* pCols, TAOS_MULTI_BIND* bind
int16_t lastColId = -1;
bool colInOrder = true;
if (NULL == *pTSchema) {
if (NULL == pTSchema || NULL == *pTSchema) {
*pTSchema = tBuildTSchema(pSchema, pDataBlock->pMeta->tableInfo.numOfColumns, pDataBlock->pMeta->sversion);
}
@ -697,7 +697,7 @@ int32_t qBindStmtStbColsValue2(void* pBlock, SArray* pCols, TAOS_STMT2_BIND* bin
bool colInOrder = true;
int ncharColNums = 0;
if (NULL == *pTSchema) {
if (NULL == pTSchema || NULL == *pTSchema) {
*pTSchema = tBuildTSchema(pSchema, pDataBlock->pMeta->tableInfo.numOfColumns, pDataBlock->pMeta->sversion);
}
@ -746,7 +746,7 @@ int32_t qBindStmtStbColsValue2(void* pBlock, SArray* pCols, TAOS_STMT2_BIND* bin
} else if (TSDB_DATA_TYPE_GEOMETRY == pColSchema->type) {
code = initCtxAsText();
if (code) {
qError("geometry init failed");
qError("geometry init failed:%s", tstrerror(code));
goto _return;
}
uint8_t* buf = bind[c].buffer;
@ -960,7 +960,7 @@ int32_t qBindStmt2RowValue(void* pBlock, SArray* pCols, TAOS_STMT2_BIND* bind, c
int16_t lastColId = -1;
bool colInOrder = true;
if (NULL == *pTSchema) {
if (NULL == pTSchema || NULL == *pTSchema) {
*pTSchema = tBuildTSchema(pSchema, pDataBlock->pMeta->tableInfo.numOfColumns, pDataBlock->pMeta->sversion);
}
@ -992,7 +992,7 @@ int32_t qBindStmt2RowValue(void* pBlock, SArray* pCols, TAOS_STMT2_BIND* bind, c
} else if (TSDB_DATA_TYPE_GEOMETRY == pColSchema->type) {
code = initCtxAsText();
if (code) {
qError("geometry init failed");
qError("geometry init failed:%s", tstrerror(code));
goto _return;
}
uint8_t *buf = bind[c].buffer;