diff --git a/MAC/APL/MainCU/src/MACScheduler/MACScheduler.cc b/MAC/APL/MainCU/src/MACScheduler/MACScheduler.cc index e8610c4bf356eea1427a30e9859679c0f41dd46d..69989c01ca7b4f477a692631de805256295761a2 100644 --- a/MAC/APL/MainCU/src/MACScheduler/MACScheduler.cc +++ b/MAC/APL/MainCU/src/MACScheduler/MACScheduler.cc @@ -1074,9 +1074,9 @@ void MACScheduler::_updateActiveList() } // walk through the list, prepare PVSS for the new obs, update own admin lists. - int32 idx = activeSubTasks.size() - 1; - for ( ; idx >= 0; idx--) { - Json::Value subtask = activeSubTasks[idx]; + int32 idx2 = activeSubTasks.size() - 1; + for ( ; idx2 >= 0; idx2--) { + Json::Value subtask = activeSubTasks[idx2]; // if (subtask.processType=="RESERVATION" || subtask.processType=="MAINTENANCE") { // continue; @@ -1169,10 +1169,10 @@ void MACScheduler::_updateFinishedList() // walk through the list, prepare PVSS for the new obs, update own admin lists. // We must show the last part of the (optional) limited list. - int32 idx = finishingSubTasks.size() - 1; - int32 limit = idx - (MIN2(MIN2(finishingSubTasks.size(), itsMaxFinished), (uint32)freeSpace) - 1); - for ( ; idx >= limit ; idx--) { - Json::Value subtask = finishingSubTasks[idx]; + int32 idx2 = finishingSubTasks.size() - 1; + int32 limit2 = idx2 - (MIN2(MIN2(finishingSubTasks.size(), itsMaxFinished), (uint32)freeSpace) - 1); + for ( ; idx2 >= limit2 ; idx2--) { + Json::Value subtask = finishingSubTasks[idx2]; // if (subtask.processType=="RESERVATION" || subtask.processType=="MAINTENANCE") { // continue;