From 9499a1c3c8101975d5100f010c855ff454e1f295 Mon Sep 17 00:00:00 2001 From: dapan1121 Date: Mon, 3 Jul 2023 10:28:59 +0800 Subject: [PATCH] fix: remove abs --- source/libs/scheduler/src/schTask.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/source/libs/scheduler/src/schTask.c b/source/libs/scheduler/src/schTask.c index 41357b2a41..d4ded2dd8b 100644 --- a/source/libs/scheduler/src/schTask.c +++ b/source/libs/scheduler/src/schTask.c @@ -769,7 +769,7 @@ int32_t schSetTaskCandidateAddrs(SSchJob *pJob, SSchTask *pTask) { SCH_ERR_RET(schSetAddrsFromNodeList(pJob, pTask)); - pTask->candidateIdx = abs(taosRand() % taosArrayGetSize(pTask->candidateAddrs)); + pTask->candidateIdx = taosRand() % taosArrayGetSize(pTask->candidateAddrs); /* for (int32_t i = 0; i < job->dataSrcEps.numOfEps && addNum < SCH_MAX_CANDIDATE_EP_NUM; ++i) { -- GitLab