Index: src/libchcore/TBasePathData.cpp =================================================================== diff -u -re96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3 -rbd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c --- src/libchcore/TBasePathData.cpp (.../TBasePathData.cpp) (revision e96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3) +++ src/libchcore/TBasePathData.cpp (.../TBasePathData.cpp) (revision bd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c) @@ -222,7 +222,6 @@ return m_vEntries.at(boost::numeric_cast(fcIndex)); } - TBasePathDataPtr TBasePathDataContainer::FindByID(size_t stObjectID) const { boost::shared_lock lock(m_lock); @@ -264,6 +263,19 @@ return boost::numeric_cast(m_vEntries.size()); } + bool TBasePathDataContainer::AllMarkedAsSkipFurtherProcessing() const + { + boost::shared_lock lock(m_lock); + + for (const TBasePathDataPtr& spBasePath : m_vEntries) + { + if (!spBasePath->GetSkipFurtherProcessing()) + return false; + } + + return true; + } + TBasePathDataContainer& TBasePathDataContainer::operator=(const TPathContainer& tPaths) { boost::unique_lock lock(m_lock); Index: src/libchcore/TBasePathData.h =================================================================== diff -u -re96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3 -rbd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c --- src/libchcore/TBasePathData.h (.../TBasePathData.h) (revision e96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3) +++ src/libchcore/TBasePathData.h (.../TBasePathData.h) (revision bd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c) @@ -114,6 +114,8 @@ bool IsEmpty() const; file_count_t GetCount() const; + bool AllMarkedAsSkipFurtherProcessing() const; + void Store(const ISerializerContainerPtr& spContainer) const; void Load(const ISerializerContainerPtr& spContainer); Index: src/libchcore/TSubTaskArray.cpp =================================================================== diff -u -re96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3 -rbd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c --- src/libchcore/TSubTaskArray.cpp (.../TSubTaskArray.cpp) (revision e96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3) +++ src/libchcore/TSubTaskArray.cpp (.../TSubTaskArray.cpp) (revision bd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c) @@ -142,6 +142,11 @@ return eResult; } + bool TSubTasksArray::AreAllBasePathsProcessed() const + { + return m_rSubTaskContext.GetBasePaths()->AllMarkedAsSkipFurtherProcessing(); + } + void TSubTasksArray::AddSubTask(const TSubTaskBasePtr& spOperation, bool bIsPartOfEstimation) { m_vSubTasks.push_back(std::make_pair(spOperation, bIsPartOfEstimation)); Index: src/libchcore/TSubTaskArray.h =================================================================== diff -u -re96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3 -rbd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c --- src/libchcore/TSubTaskArray.h (.../TSubTaskArray.h) (revision e96806b7f8ff7ca7e9f4afbea603e6351a3dc3e3) +++ src/libchcore/TSubTaskArray.h (.../TSubTaskArray.h) (revision bd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c) @@ -59,6 +59,9 @@ TSubTaskBase::ESubOperationResult Execute(const IFeedbackHandlerPtr& spFeedbackHandler, bool bRunOnlyEstimationSubTasks); + // checks if the fast move already marked all base paths as not be be further processed + bool AreAllBasePathsProcessed() const; + private: TSubTasksArray(const TSubTasksArray& rSrc); TSubTasksArray& operator=(const TSubTasksArray& rSrc); Index: src/libchcore/TTask.cpp =================================================================== diff -u -rba618764ec3c9221fa704e905a9f807bd85ed4c5 -rbd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c --- src/libchcore/TTask.cpp (.../TTask.cpp) (revision ba618764ec3c9221fa704e905a9f807bd85ed4c5) +++ src/libchcore/TTask.cpp (.../TTask.cpp) (revision bd349309a6dcd25f8d6dc3348a9dc1c95ac4cc6c) @@ -522,7 +522,10 @@ // prepare context for subtasks if (bReadTasksSize) eResult = m_tSubTasksArray.Execute(spFeedbackHandler, true); - if (eResult == TSubTaskBase::eSubResult_Continue) + + // go into wait state only in case the preprocessing did not finish the operation already + // (only fast move can do that right now) + if (eResult == TSubTaskBase::eSubResult_Continue && !m_tSubTasksArray.AreAllBasePathsProcessed()) { TScopedRunningTimeTrackerPause scopedPause(tProcessingGuard);