fix(query): invalid buffer page
This commit is contained in:
parent
3bbf5405c6
commit
f984e67eaa
|
@ -136,6 +136,7 @@ struct SResultRowEntryInfo* getResultEntryInfo(const SResultRow* pRow, int32_t i
|
||||||
static FORCE_INLINE SResultRow* getResultRowByPos(SDiskbasedBuf* pBuf, SResultRowPosition* pos, bool forUpdate) {
|
static FORCE_INLINE SResultRow* getResultRowByPos(SDiskbasedBuf* pBuf, SResultRowPosition* pos, bool forUpdate) {
|
||||||
SFilePage* bufPage = (SFilePage*)getBufPage(pBuf, pos->pageId);
|
SFilePage* bufPage = (SFilePage*)getBufPage(pBuf, pos->pageId);
|
||||||
if (!bufPage) {
|
if (!bufPage) {
|
||||||
|
uFatal("failed to get the buffer page:%d since %s", pos->pageId, terrstr());
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
if (forUpdate) {
|
if (forUpdate) {
|
||||||
|
|
|
@ -482,7 +482,7 @@ void* getBufPage(SDiskbasedBuf* pBuf, int32_t id) {
|
||||||
|
|
||||||
SPageInfo** pInfo = (SPageInfo**)((*pi)->pn->data);
|
SPageInfo** pInfo = (SPageInfo**)((*pi)->pn->data);
|
||||||
if (*pInfo != *pi) {
|
if (*pInfo != *pi) {
|
||||||
terrno = TSDB_CODE_QRY_SYS_ERROR;
|
terrno = TSDB_CODE_APP_ERROR;
|
||||||
uError("inconsistently data in paged buffer, pInfo:%p, pi:%p, %s", *pInfo, *pi, pBuf->id);
|
uError("inconsistently data in paged buffer, pInfo:%p, pi:%p, %s", *pInfo, *pi, pBuf->id);
|
||||||
return NULL;
|
return NULL;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue