add user req

This commit is contained in:
yihaoDeng 2024-09-29 15:19:18 +08:00
parent b15506c1de
commit ee5794f494
3 changed files with 9 additions and 3 deletions

View File

@ -446,7 +446,7 @@ void transDQDestroy(SDelayQueue* queue, void (*freeFunc)(void* arg));
SDelayTask* transDQSched(SDelayQueue* queue, void (*func)(void* arg), void* arg, uint64_t timeoutMs);
void transDQCancel(SDelayQueue* queue, SDelayTask* task);
bool transRepEpsetIsEqual(SReqEpSet* a, SReqEpSet* b);
bool transReqEpsetIsEqual(SReqEpSet* a, SReqEpSet* b);
bool transCompareReqAndUserEpset(SReqEpSet* a, SEpSet* b);
/*

View File

@ -1592,7 +1592,7 @@ FORCE_INLINE int32_t cliMayCvtFqdnToIp(SReqEpSet* pEpSet, const SCvtAddr* pCvtAd
FORCE_INLINE bool cliIsEpsetUpdated(int32_t code, SReqCtx* pCtx) {
if (code != 0) return false;
return transRepEpsetIsEqual(pCtx->epSet, pCtx->origEpSet) ? false : true;
return transReqEpsetIsEqual(pCtx->epSet, pCtx->origEpSet) ? false : true;
}
FORCE_INLINE int32_t cliBuildExceptResp(SCliThrd* pThrd, SCliReq* pReq, STransMsg* pResp) {

View File

@ -667,7 +667,13 @@ void transPrintEpSet(SEpSet* pEpSet) {
len += snprintf(buf + len, sizeof(buf) - len, "}");
tTrace("%s, inUse:%d", buf, pEpSet->inUse);
}
bool transRepEpsetIsEqual(SReqEpSet* a, SReqEpSet* b) {
bool transReqEpsetIsEqual(SReqEpSet* a, SReqEpSet* b) {
if (a == NULL && b == NULL) {
return true;
} else if (a == NULL || b == NULL) {
return false;
}
if (a->numOfEps != b->numOfEps || a->inUse != b->inUse) {
return false;
}