Problem 2323

Summary: Region import logic flawed
Product: Geant4 Reporter: Shang Jiaxuan <shangjiaxuan>
Component: persistency/gdmlAssignee: Gabriele Cosmo <Gabriele.Cosmo>
Status: RESOLVED FIXED    
Severity: normal    
Priority: P4    
Version: 10.7   
Hardware: All   
OS: All   

Description Shang Jiaxuan 2021-02-03 08:33:34 CET
Region import looks for Region in auxGlobalList to add the region. However, if some other global auxiliary info is present before a Region auxiliary info, the import is currently aborted, and the regions after that point is not imported. Suggested fix is to change the return in the item iteration loop to continue (line 101 in G4GDMLParser.cc).

Also the destructor does not make sense not delete the ullist and rlist when user gives it G4GDMLWriteStructure. It allocates no matter if the user offers a G4GDMLWriteStructure or not, and should deallocate it when it is done. These fields are only used in RegionExport function, and is allocated there.

Suggested and pull discussion is started at https://github.com/Geant4/geant4/pull/19/
Comment 1 Gabriele Cosmo 2021-02-03 09:46:30 CET
As noted in GitHub PR#19, fixes will be be included in next patch release.