fix(query): add null check.

This commit is contained in:
Haojun Liao 2023-05-19 15:54:46 +08:00
parent 03237f2cc7
commit be35194d16
1 changed files with 3 additions and 0 deletions

View File

@ -225,6 +225,9 @@ int32_t tsdbCacherowsReaderOpen(void* pVnode, int32_t type, void* pTableIdList,
void* tsdbCacherowsReaderClose(void* pReader) { void* tsdbCacherowsReaderClose(void* pReader) {
SCacheRowsReader* p = pReader; SCacheRowsReader* p = pReader;
if (p == NULL) {
return NULL;
}
if (p->pSchema != NULL) { if (p->pSchema != NULL) {
for (int32_t i = 0; i < p->pSchema->numOfCols; ++i) { for (int32_t i = 0; i < p->pSchema->numOfCols; ++i) {