Problem 653

Summary: Over delete of required objects in G4CascadeInterface
Product: Geant4 Reporter: tkoi
Component: processes/hadronic/modelsAssignee: Hans-Peter.Wellisch
Status: RESOLVED FIXED    
Severity: major    
Priority: P2    
Version: 6.2   
Hardware: Other   
OS: All   
URL: http://geant4-hn.slac.stanford.edu:5090/HyperNews/public/get/emprocess/171.html

Description tkoi 2004-07-27 18:17:20 CEST
It looks like there are over delete of G4DynamicParticle objects at
G4CascadeInterface.cc::ApplyYourself()

At 395th line of G4CascadeInterface.cc
   if(cascadeParticle != NULL) delete cascadeParticle;
However the cascadeParticle (G4DynamicParticle) is required at tracking
process of those secondary particles.
As the result, strange performances will happen in the later calculations and
often terminated with core dump.
See
http://geant4-hn.slac.stanford.edu:5090/HyperNews/public/get/emprocess/171.html

Next line (396th) also delete G4DynamicParticle Object.
if(aFragment != NULL) delete aFragment;
This line possibly makes same trouble.

If I commented out these two lines, I got reasonable result without unexpected
termination of the program.

This trouble come from v6.2 and is not solved in patch01.
Comment 1 Hans-Peter.Wellisch 2004-09-10 02:58:59 CEST
Thank you for reporting this.

Many greetings,

Hans-Peter.