fix:add assert for debug
This commit is contained in:
parent
6f6239a7fa
commit
d9b3c638c3
|
@ -2453,6 +2453,9 @@ int32_t tColDataAddValueByDataBlock(SColData *pColData, int8_t type, int32_t byt
|
||||||
code = tColDataAppendValueImpl[pColData->flag][CV_FLAG_NULL](pColData, NULL, 0);
|
code = tColDataAppendValueImpl[pColData->flag][CV_FLAG_NULL](pColData, NULL, 0);
|
||||||
if (code) goto _exit;
|
if (code) goto _exit;
|
||||||
} else {
|
} else {
|
||||||
|
if(ASSERT(varDataTLen(data + offset) <= bytes)){
|
||||||
|
uError("var data length invalid, varDataTLen(data + offset):%d <= bytes:%d", (int)varDataTLen(data + offset), bytes);
|
||||||
|
}
|
||||||
code = tColDataAppendValueImpl[pColData->flag][CV_FLAG_VALUE](pColData, (uint8_t *)varDataVal(data + offset),
|
code = tColDataAppendValueImpl[pColData->flag][CV_FLAG_VALUE](pColData, (uint8_t *)varDataVal(data + offset),
|
||||||
varDataLen(data + offset));
|
varDataLen(data + offset));
|
||||||
}
|
}
|
||||||
|
|
|
@ -656,6 +656,9 @@ int rawBlockBindData(SQuery* query, STableMeta* pTableMeta, void* data, SVCreate
|
||||||
} else {
|
} else {
|
||||||
pStart += colLength[j];
|
pStart += colLength[j];
|
||||||
}
|
}
|
||||||
|
if(ASSERT(pCol->nVal == numOfRows)){
|
||||||
|
uError("tFields is null, pCol->nVal:%d != numOfRows:%d", pCol->nVal, numOfRows);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}else{
|
}else{
|
||||||
for (int i = 0; i < numFields; i++) {
|
for (int i = 0; i < numFields; i++) {
|
||||||
|
@ -684,6 +687,9 @@ int rawBlockBindData(SQuery* query, STableMeta* pTableMeta, void* data, SVCreate
|
||||||
} else {
|
} else {
|
||||||
pStart += colLength[i];
|
pStart += colLength[i];
|
||||||
}
|
}
|
||||||
|
if(ASSERT(pCol->nVal == numOfRows)){
|
||||||
|
uError("tFields is not null, pCol->nVal:%d != numOfRows:%d", pCol->nVal, numOfRows);
|
||||||
|
}
|
||||||
boundInfo->pColIndex[j] = -1;
|
boundInfo->pColIndex[j] = -1;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue