fix(query): fix bugs caused by refactor.
This commit is contained in:
parent
82c10fd709
commit
7a90e68667
|
@ -40,7 +40,7 @@ static int32_t buildRetrieveTableRsp(SSDataBlock* pBlock, int32_t numOfCols, SRe
|
|||
(*pRsp)->numOfRows = htobe64((int64_t)pBlock->info.rows);
|
||||
(*pRsp)->numOfCols = htonl(numOfCols);
|
||||
|
||||
int32_t len = blockEncode(pBlock, (*pRsp)->data + sizeof(int32_t)*2, numOfCols);
|
||||
int32_t len = blockEncode(pBlock, (*pRsp)->data + PAYLOAD_PREFIX_LEN, numOfCols);
|
||||
SET_PAYLOAD_LEN((*pRsp)->data, len, len);
|
||||
|
||||
int32_t payloadLen = len + PAYLOAD_PREFIX_LEN;
|
||||
|
|
|
@ -1953,14 +1953,13 @@ int32_t qExplainGetRspFromCtx(void *ctx, SRetrieveTableRsp **pRsp) {
|
|||
rsp->completed = 1;
|
||||
rsp->numOfRows = htobe64((int64_t)rowNum);
|
||||
|
||||
int32_t len = blockEncode(pBlock, rsp->data + sizeof(int32_t)*2, taosArrayGetSize(pBlock->pDataBlock));
|
||||
int32_t len = blockEncode(pBlock, rsp->data + PAYLOAD_PREFIX_LEN, taosArrayGetSize(pBlock->pDataBlock));
|
||||
|
||||
rsp->compLen = htonl(len);
|
||||
rsp->payloadLen = rsp->compLen;
|
||||
rsp->payloadLen = htonl(len);
|
||||
rsp->compressed = 0;
|
||||
|
||||
((int32_t*)rsp->data)[0] = len;
|
||||
((int32_t*)rsp->data)[1] = len;
|
||||
SET_PAYLOAD_LEN(rsp->data, len, len);
|
||||
|
||||
blockDataDestroy(pBlock);
|
||||
|
||||
|
|
|
@ -693,7 +693,7 @@ int32_t streamAddBlockIntoDispatchMsg(const SSDataBlock* pBlock, SStreamDispatch
|
|||
int32_t numOfCols = (int32_t)taosArrayGetSize(pBlock->pDataBlock);
|
||||
pRetrieve->numOfCols = htonl(numOfCols);
|
||||
|
||||
int32_t actualLen = blockEncode(pBlock, pRetrieve->data, numOfCols);
|
||||
int32_t actualLen = blockEncode(pBlock, pRetrieve->data + PAYLOAD_PREFIX_LEN, numOfCols);
|
||||
SET_PAYLOAD_LEN(pRetrieve->data, actualLen, actualLen);
|
||||
|
||||
int32_t payloadLen = actualLen + PAYLOAD_PREFIX_LEN;
|
||||
|
|
Loading…
Reference in New Issue