From da33172b90e2726d5d42022b23bd092b671e1968 Mon Sep 17 00:00:00 2001 From: ribes Date: Fri, 23 May 2008 14:19:43 +0000 Subject: [PATCH] - Bu when using SALOME_BATCH --- src/Container/SALOME_ContainerManager.cxx | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/src/Container/SALOME_ContainerManager.cxx b/src/Container/SALOME_ContainerManager.cxx index b3be8a826..fe6cc3165 100644 --- a/src/Container/SALOME_ContainerManager.cxx +++ b/src/Container/SALOME_ContainerManager.cxx @@ -508,9 +508,15 @@ GiveContainer(const Engines::MachineParameters& params, if(valenv) if (strcmp(valenv,"1")==0) { - if(_batchLaunchedContainers.empty()) - fillBatchLaunchedContainers(); - return *(_batchLaunchedContainersIter++); + if(_batchLaunchedContainers.empty()) + fillBatchLaunchedContainers(); + + if (_batchLaunchedContainersIter == _batchLaunchedContainers.end()) + _batchLaunchedContainersIter = _batchLaunchedContainers.begin(); + + Engines::Container_ptr rtn = Engines::Container::_duplicate(*_batchLaunchedContainersIter); + _batchLaunchedContainersIter++; + return rtn; } return StartContainer(params,policy,componentList); } -- 2.39.2