From 02aaa95322f23c4313ba91ffb13f220feb31c88d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Einar=20El=C3=A9n?= Date: Fri, 18 Aug 2023 21:29:42 +0200 Subject: [PATCH] Patch buffer overflow --- src/Ecal/EcalVetoProcessor.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Ecal/EcalVetoProcessor.cxx b/src/Ecal/EcalVetoProcessor.cxx index 167b3c4..715a2bc 100644 --- a/src/Ecal/EcalVetoProcessor.cxx +++ b/src/Ecal/EcalVetoProcessor.cxx @@ -910,7 +910,7 @@ void EcalVetoProcessor::fillIsolatedHitMap( // these ideas are only cell/module (must ignore layer) std::vector cellNbrIds = geometry_->getNN(id); - for (int k = 0; k < 6; k++) { + for (int k = 0; k < cellNbrIds.size(); k++) { // update neighbor ID to the current layer cellNbrIds[k] = ldmx::EcalID(id.layer(), cellNbrIds[k].module(), cellNbrIds[k].cell());