[TD-715] incorrect handling of error code when creating vnode failed
This commit is contained in:
parent
a47ec20ed8
commit
8f1cee4aad
|
@ -678,8 +678,9 @@ static void mnodeProcessCreateVnodeRsp(SRpcMsg *rpcMsg) {
|
||||||
SMnodeMsg *mnodeMsg = rpcMsg->handle;
|
SMnodeMsg *mnodeMsg = rpcMsg->handle;
|
||||||
mnodeMsg->received++;
|
mnodeMsg->received++;
|
||||||
if (rpcMsg->code == TSDB_CODE_SUCCESS) {
|
if (rpcMsg->code == TSDB_CODE_SUCCESS) {
|
||||||
mnodeMsg->code = rpcMsg->code;
|
|
||||||
mnodeMsg->successed++;
|
mnodeMsg->successed++;
|
||||||
|
} else {
|
||||||
|
mnodeMsg->code = rpcMsg->code;
|
||||||
}
|
}
|
||||||
|
|
||||||
SVgObj *pVgroup = mnodeMsg->pVgroup;
|
SVgObj *pVgroup = mnodeMsg->pVgroup;
|
||||||
|
@ -702,7 +703,7 @@ static void mnodeProcessCreateVnodeRsp(SRpcMsg *rpcMsg) {
|
||||||
code = TSDB_CODE_MND_SDB_ERROR;
|
code = TSDB_CODE_MND_SDB_ERROR;
|
||||||
}
|
}
|
||||||
|
|
||||||
dnodeSendRpcMnodeWriteRsp(mnodeMsg, code);
|
dnodeSendRpcMnodeWriteRsp(mnodeMsg, mnodeMsg->code);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue