From bd8dc2d7eada4a987cd82e18cf30ac284b67e514 Mon Sep 17 00:00:00 2001 From: Nathan Brei Date: Sun, 27 Oct 2024 20:07:23 -0400 Subject: [PATCH] Fix JFoldArrow --- src/libraries/JANA/Topology/JFoldArrow.h | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/libraries/JANA/Topology/JFoldArrow.h b/src/libraries/JANA/Topology/JFoldArrow.h index c865c5b62..c7b9b193f 100644 --- a/src/libraries/JANA/Topology/JFoldArrow.h +++ b/src/libraries/JANA/Topology/JFoldArrow.h @@ -93,8 +93,10 @@ class JFoldArrow : public JTriggeredArrow { throw JException("JFoldArrow received a child with the wrong event level"); } - auto parent = const_cast(&event->GetParent(m_parent_level)); - m_folder->DoFold(*event, *parent); + if (m_folder != nullptr) { + auto parent = const_cast(&event->GetParent(m_parent_level)); + m_folder->DoFold(*event, *parent); + } status = JArrowMetrics::Status::KeepGoing; outputs[0] = {event, CHILD_OUT};