Skip to content
Snippets Groups Projects
Commit 474989dc authored by Scott Snyder's avatar Scott Snyder Committed by Jean-Baptiste De Vivie De Regie
Browse files

DerivationFrameworkMCTruth: Use decoration handle.

DerivationFrameworkMCTruth: Use decoration handle.

In TruthLinkRepointTool, use a decoration handle to write the
output decoration, so that it will get properly locked.

See ATLASRECTS-8008.
parent 42dc4ff7
No related branches found
Tags release/24.0.69
3 merge requests!756432024-11-06: merge of 24.0 into main,!75597DerivationFrameworkMCTruth: Use decoration handle.,!75127Draft: Seeder types rebase2 grid fix
/*
Copyright (C) 2002-2023 CERN for the benefit of the ATLAS collaboration
Copyright (C) 2002-2024 CERN for the benefit of the ATLAS collaboration
*/
/////////////////////////////////////////////////////////////////
......@@ -48,8 +48,9 @@ StatusCode DerivationFramework::TruthLinkRepointTool::addBranches() const {
// Retrieve the truth collections
std::vector<const xAOD::TruthParticleContainer*> targets{};
targets.reserve(m_targetKeys.size());
const SG::AuxElement::Decorator< ElementLink<xAOD::TruthParticleContainer> > output_decorator(m_decOutput);
SG::WriteDecorHandle<xAOD::IParticleContainer, ElementLink<xAOD::TruthParticleContainer> >
output_decorator (m_decorKey, ctx);
for (const SG::ReadHandleKey<xAOD::TruthParticleContainer>& key : m_targetKeys) {
SG::ReadHandle<xAOD::TruthParticleContainer> readHandle{key, ctx};
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment