From 6277447c640a6d63c73d9a44ae390648554dd983 Mon Sep 17 00:00:00 2001 From: Manuel Huber Date: Wed, 27 Nov 2024 09:56:47 +0100 Subject: [PATCH] RMGSteppingAction: only output parameters on master --- src/RMGSteppingAction.cc | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/RMGSteppingAction.cc b/src/RMGSteppingAction.cc index a54444e9..ae66a8f4 100644 --- a/src/RMGSteppingAction.cc +++ b/src/RMGSteppingAction.cc @@ -18,6 +18,7 @@ #include "G4GenericMessenger.hh" #include "G4Ions.hh" #include "G4Step.hh" +#include "G4Threading.hh" #include "RMGEventAction.hh" #include "RMGLog.hh" @@ -59,7 +60,7 @@ void RMGSteppingAction::UserSteppingAction(const G4Step* step) { void RMGSteppingAction::SetDaughterKillLifetime(double max_lifetime) { fDaughterKillLifetime = max_lifetime; - if (fDaughterKillLifetime > 0) { + if (fDaughterKillLifetime > 0 && G4Threading::IsMasterThread()) { RMGLog::OutFormat(RMGLog::summary, "Enabled killing of daughter nuclei with a lifetime longer than {} us.", fDaughterKillLifetime / CLHEP::us);