From d0e6be3d1416a0722c724031a4c8c0aa86cb6bc3 Mon Sep 17 00:00:00 2001 From: Will Leight <wleight@cern.ch> Date: Wed, 30 Aug 2017 16:33:10 +0200 Subject: [PATCH] Fix for cherry-pick to master. --- MuonSpectrometer/MuonTruthAlgs/src/MuonTruthDecorationAlg.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MuonSpectrometer/MuonTruthAlgs/src/MuonTruthDecorationAlg.cxx b/MuonSpectrometer/MuonTruthAlgs/src/MuonTruthDecorationAlg.cxx index 9d8879ac8de..3d1f3def147 100644 --- a/MuonSpectrometer/MuonTruthAlgs/src/MuonTruthDecorationAlg.cxx +++ b/MuonSpectrometer/MuonTruthAlgs/src/MuonTruthDecorationAlg.cxx @@ -468,8 +468,8 @@ namespace Muon { } } std::vector<float> emptyVec; - for( const auto& col : trackRecords ){ - const std::string name = col.second; + for( unsigned int i=0;i<m_trackRecordCollectionNames.size();i++){ + const std::string name = m_trackRecordCollectionNames.at(i).key(); if(!truthParticle.isAvailable<std::vector<float> >(name+"_cov_extr")){ truthParticle.auxdata<std::vector<float> >(name+"_cov_extr")=emptyVec; } -- GitLab