fix uninitialized varaible usage
This commit is contained in:
parent
269a7cead6
commit
6b8e149d50
|
@ -1824,6 +1824,7 @@ int taos_insert_lines(TAOS* taos, char* lines[], int numLines) {
|
|||
cleanup:
|
||||
tscDebug("taos_insert_lines finish inserting %d lines. code: %d", numLines, code);
|
||||
points = TARRAY_GET_START(lpPoints);
|
||||
numPoints = taosArrayGetSize(lpPoints);
|
||||
for (int i=0; i<numPoints; ++i) {
|
||||
destroySmlDataPoint(points+i);
|
||||
}
|
||||
|
|
|
@ -6066,11 +6066,11 @@ int32_t setAlterTableInfo(SSqlObj* pSql, struct SSqlInfo* pInfo) {
|
|||
return invalidOperationMsg(pMsg, msg22);
|
||||
}
|
||||
|
||||
SSchema* pSchema = (SSchema*) pTableMetaInfo->pTableMeta->schema;
|
||||
int16_t numOfColumns = pTableMetaInfo->pTableMeta->tableInfo.numOfColumns;
|
||||
SSchema* pSchema = tscGetTableTagSchema(pTableMetaInfo->pTableMeta);
|
||||
int16_t numOfTags = tscGetNumOfTags(pTableMetaInfo->pTableMeta);
|
||||
int16_t i;
|
||||
uint32_t nLen = 0;
|
||||
for (i = 0; i < numOfColumns; ++i) {
|
||||
for (i = 0; i < numOfTags; ++i) {
|
||||
nLen += pSchema[i].colId != columnIndex.columnIndex ? pSchema[i].bytes : pItem->bytes;
|
||||
}
|
||||
if (nLen >= TSDB_MAX_TAGS_LEN) {
|
||||
|
|
Loading…
Reference in New Issue