From 7251a56b4069ddc943bde7701bc89dff3dbde3bf Mon Sep 17 00:00:00 2001 From: Srecko Morovic Date: Thu, 13 Jul 2023 23:33:50 +0200 Subject: [PATCH] fix issue with early deletion of files (was not checking full vector range) --- EventFilter/Utilities/interface/FedRawDataInputSource.h | 1 - EventFilter/Utilities/src/FedRawDataInputSource.cc | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/EventFilter/Utilities/interface/FedRawDataInputSource.h b/EventFilter/Utilities/interface/FedRawDataInputSource.h index dea0500813209..9b5189d1e5f37 100644 --- a/EventFilter/Utilities/interface/FedRawDataInputSource.h +++ b/EventFilter/Utilities/interface/FedRawDataInputSource.h @@ -168,7 +168,6 @@ class FedRawDataInputSource : public edm::RawInputSource { std::list> fileNamesToDelete_; std::mutex fileDeleteLock_; std::vector streamFileTracker_; - unsigned int nStreams_ = 0; unsigned int checkEvery_ = 10; //supervisor thread wakeup diff --git a/EventFilter/Utilities/src/FedRawDataInputSource.cc b/EventFilter/Utilities/src/FedRawDataInputSource.cc index 4f60680f43c8c..9a608dd182576 100644 --- a/EventFilter/Utilities/src/FedRawDataInputSource.cc +++ b/EventFilter/Utilities/src/FedRawDataInputSource.cc @@ -685,7 +685,7 @@ void FedRawDataInputSource::read(edm::EventPrincipal& eventPrincipal) { auto it = filesToDelete_.begin(); while (it != filesToDelete_.end()) { bool fileIsBeingProcessed = false; - for (unsigned int i = 0; i < nStreams_; i++) { + for (unsigned int i = 0; i < streamFileTracker_.size(); i++) { if (it->first == streamFileTracker_.at(i)) { fileIsBeingProcessed = true; break;