fix(stream): adjust the ptr.
This commit is contained in:
parent
4c6bc4d2c3
commit
5344efe181
|
@ -297,7 +297,6 @@ int32_t tqReaderSeek(STqReader* pReader, int64_t ver, const char* id) {
|
|||
|
||||
int32_t extractMsgFromWal(SWalReader* pReader, void** pItem, int64_t maxVer, const char* id) {
|
||||
int32_t code = 0;
|
||||
SWalCont* pCont = &pReader->pHead->head;
|
||||
|
||||
while(1) {
|
||||
code = walNextValidMsg(pReader);
|
||||
|
@ -305,7 +304,8 @@ int32_t extractMsgFromWal(SWalReader* pReader, void** pItem, int64_t maxVer, con
|
|||
return code;
|
||||
}
|
||||
|
||||
int64_t ver = pCont->version;
|
||||
SWalCont* pCont = &pReader->pHead->head;
|
||||
int64_t ver = pCont->version;
|
||||
if (ver > maxVer) {
|
||||
tqDebug("maxVer in WAL:%" PRId64 " reached current:%" PRId64 ", do not scan wal anymore, %s", maxVer, ver, id);
|
||||
return TSDB_CODE_SUCCESS;
|
||||
|
|
Loading…
Reference in New Issue