提交 d2253e0b 编写于 作者: S Shengliang Guan

minor changes

上级 f0e69747
......@@ -609,14 +609,12 @@ static int32_t mndProcessConfigDnodeReq(SMnodeMsg *pReq) {
SEpSet epSet = mndGetDnodeEpset(pDnode);
mndReleaseDnode(pMnode, pDnode);
SDCfgDnodeReq *pCfgDnode = rpcMallocCont(sizeof(SDCfgDnodeReq));
pCfgDnode->dnodeId = htonl(cfgReq.dnodeId);
memcpy(pCfgDnode->config, cfgReq.config, TSDB_DNODE_CONFIG_LEN);
SRpcMsg rpcMsg = {.msgType = TDMT_DND_CONFIG_DNODE,
.pCont = pCfgDnode,
.contLen = sizeof(SDCfgDnodeReq),
.ahandle = pReq->rpcMsg.ahandle};
int32_t bufLen = tSerializeSMCfgDnodeReq(NULL, 0, &cfgReq);
void *pBuf = rpcMallocCont(bufLen);
tSerializeSMCfgDnodeReq(pBuf, bufLen, &cfgReq);
SRpcMsg rpcMsg = {
.msgType = TDMT_DND_CONFIG_DNODE, .pCont = pBuf, .contLen = bufLen, .ahandle = pReq->rpcMsg.ahandle};
mInfo("dnode:%d, app:%p config:%s req send to dnode", cfgReq.dnodeId, rpcMsg.ahandle, cfgReq.config);
mndSendReqToDnode(pMnode, &epSet, &rpcMsg);
......
......@@ -223,8 +223,8 @@ void *mndBuildCreateVnodeReq(SMnode *pMnode, SDnodeObj *pDnode, SDbObj *pDb, SVg
return NULL;
}
pReplica->id = htonl(pVgidDnode->id);
pReplica->port = htons(pVgidDnode->port);
pReplica->id = pVgidDnode->id;
pReplica->port = pVgidDnode->port;
memcpy(pReplica->fqdn, pVgidDnode->fqdn, TSDB_FQDN_LEN);
mndReleaseDnode(pMnode, pVgidDnode);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册