aboutsummaryrefslogtreecommitdiffstats
path: root/src/G4BeamTestUserSteppingAction.cxx
diff options
context:
space:
mode:
Diffstat (limited to 'src/G4BeamTestUserSteppingAction.cxx')
-rw-r--r--src/G4BeamTestUserSteppingAction.cxx2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/G4BeamTestUserSteppingAction.cxx b/src/G4BeamTestUserSteppingAction.cxx
index f81ab62..816dc4a 100644
--- a/src/G4BeamTestUserSteppingAction.cxx
+++ b/src/G4BeamTestUserSteppingAction.cxx
@@ -40,7 +40,7 @@ void G4BeamTestUserSteppingAction::UserSteppingAction(const G4Step* step)
//check if particle energy is below threshold; if true, kill the particle
G4double energy = track->GetTotalEnergy();
if(energy < threshold){
- G4cout << "SteppingAction: killing particle " << particle << " with energy " << energy << " < " << threshold << G4endl;
+ if (energy > 0) G4cout << "SteppingAction: killing particle " << particle << " with energy " << energy << " < " << threshold << G4endl;
track->SetTrackStatus(fStopAndKill);
}
}