diff --git a/source/framework/core/src/TRestProcessRunner.cxx b/source/framework/core/src/TRestProcessRunner.cxx index 1064df9dd..b8683a56e 100644 --- a/source/framework/core/src/TRestProcessRunner.cxx +++ b/source/framework/core/src/TRestProcessRunner.cxx @@ -466,11 +466,14 @@ void TRestProcessRunner::RunProcess() { if (finish) break; } + // make analysis tree filled with observables, which may used in EndProcess() fAnalysisTree->GetEntry(fAnalysisTree->GetEntries() - 1); for (int i = 0; i < fThreadNumber; i++) { fThreads[i]->EndProcess(); } - + if (fRunInfo->GetFileProcess()) { + fRunInfo->GetFileProcess()->EndProcess(); + } fProcStatus = kFinished; #ifdef TIME_MEASUREMENT diff --git a/source/framework/core/src/TRestRun.cxx b/source/framework/core/src/TRestRun.cxx index 56f801f10..9eb4af106 100644 --- a/source/framework/core/src/TRestRun.cxx +++ b/source/framework/core/src/TRestRun.cxx @@ -804,7 +804,7 @@ Int_t TRestRun::GetNextEvent(TRestEvent* targetevt, TRestAnalysisTree* targettre goto GetEventExt; } fInputEvent = eve; - if (fFileProcess != nullptr) fFileProcess->EndProcess(); + // if (fFileProcess != nullptr) fFileProcess->EndProcess(); return -1; }