| Summary: | G4EMDissociation segmentation fault | ||
|---|---|---|---|
| Product: | Geant4 | Reporter: | Gong Ding <gdiso> |
| Component: | processes/hadronic/models/em_dissociation | Assignee: | dennis.herbert.wright |
| Status: | RESOLVED FIXED | ||
| Severity: | normal | CC: | asai |
| Priority: | P5 | ||
| Version: | 9.5 | ||
| Hardware: | All | ||
| OS: | All | ||
Thanks for this report. Your fix has been implemented and will appear in Geant4 9.6 this December. |
A physics list including G4EMDissociation will get a segmentation fault when exit. The destructor of G4EMDissociation delete the cross section object. However, the base class G4VCrossSectionDataSet delete the cross section object again. G4EMDissociation::~G4EMDissociation () { if (handlerDefinedInternally) delete theExcitationHandler; delete dissociationCrossSection; <-- this line delete thePhotonSpectrum; } G4VCrossSectionDataSet::~G4VCrossSectionDataSet() { G4CrossSectionDataSetRegistry::Instance()->DeRegister(this); <-- delete again }