pMsgVersion/contLen: fix pMsg->contLen
This commit is contained in:
parent
9e5f835ac7
commit
f89406dbdc
|
@ -231,7 +231,7 @@ int tscSendMsgToServer(SSqlObj *pSql) {
|
|||
SRpcMsg rpcMsg = {
|
||||
.msgType = pSql->cmd.msgType,
|
||||
.pCont = pMsg,
|
||||
.contLen = pSql->cmd.payloadLen,
|
||||
.contLen = pSql->cmd.payloadLen + sizeof(SMsgVersion),
|
||||
.ahandle = (void*)pSql->self,
|
||||
.handle = NULL,
|
||||
.code = 0
|
||||
|
|
|
@ -135,9 +135,11 @@ static void dnodeProcessMsgFromShell(SRpcMsg *pMsg, SRpcEpSet *pEpSet) {
|
|||
return; // todo change the error code
|
||||
}
|
||||
pMsg->pCont += sizeof(*pMsgVersion);
|
||||
pMsg->contLen -= sizeof(*pMsgVersion);
|
||||
|
||||
(*dnodeProcessShellMsgFp[pMsg->msgType])(pMsg);
|
||||
|
||||
//pMsg->contLen += sizeof(*pMsgVersion);
|
||||
rpcFreeCont(pMsg->pCont - sizeof(*pMsgVersion));
|
||||
} else {
|
||||
dError("RPC %p, shell msg:%s is not processed", pMsg->handle, taosMsg[pMsg->msgType]);
|
||||
|
|
Loading…
Reference in New Issue