Problem 706

Summary: geant aborts with *** glibc detected *** double free or corruption: 0x08ad9ca8 ***
Product: Geant4 Reporter: mhindi2
Component: interfaces/GAGAssignee: yoshidah
Status: RESOLVED WORKSFORME    
Severity: normal    
Priority: P2    
Version: other   
Hardware: PC   
OS: Linux   

Description mhindi2 2004-12-27 01:07:27 CET
I get the following after I issue
/run/beamOn
*** glibc detected *** double free or corruption: 0x08ad9ca8 ***

debug gives the following backtrace

in G4UIGAG::SessionStart() from libG4UIGAG.so
in G4UIGAG::ExecuteCommand() from libG5UIGAG.so
in G4UImanager::ApplyCommand() from libG4intercoms.so
in G4UImanager::ApplyCommand() from libG4intercoms.so
in G4UIcommand::DoIt() from libG4intercoms.so
#15 0x00b0e969 in G4RunMessenger::SetNewValue () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#14 0x00b09d10 in G4RunManager::BeamOn () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#13 0x00b0cf8e in G4RunManager::RunInitialization () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#12 0x00b097bd in G4RunManagerKernel::RunInitialization () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#11 0x00b095ab in G4RunManagerKernel::BuildPhysicsTables () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#10 0x00b1a242 in G4VUserPhysicsList::BuildPhysicsTable () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#9  0x00b18aad in G4VUserPhysicsList::PreparePhysicsTable () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4run.so
#8  0x04d35698 in G4VMultipleScattering::PreparePhysicsTable () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4emutils.so
#7  0x04d0be6e in G4EmModelManager::Initialise () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4emutils.so
#6  0x00e14f9f in G4DataVector::~G4DataVector () from
/home/hindi/geant/geant4/lib/Linux-g++/libG4globman.so
#5  0x0152f445 in operator delete () from /usr/lib/libstdc++.so.6
#4  0x02cdb4ba in free () from /lib/tls/libc.so.6
#3  0x02cdaa1b in malloc_printerr () from /lib/tls/libc.so.6
#2  0x02ca3319 in abort () from /lib/tls/libc.so.6
#1  0x02ca1955 in raise () from /lib/tls/libc.so.6
#0  0x007237a2 in _dl_sysinfo_int80 () from /lib/ld-linux.so.2

Geant4.7.0 was compiled with g++ version:
g++ (GCC) 3.4.2 20041017 (Red Hat 3.4.2-6.fc3)
Comment 1 mhindi2 2004-12-28 11:50:59 CET
This is POSSIBLY related to bug #17976 in gcc 3.4/4.0 (summary:[3.4/4.0
Regression] Calls the dtor twice).

After upgrading my gcc libraries and tools to gcc (GCC) 3.4.3 20041212 (Red Hat
3.4.3-10) and recompiling GEANT4.7.0 and CLHEP and my application with the newer
gcc the abort does not take place.
Comment 2 yoshidah 2005-01-09 02:03:59 CET
this may be related with intercoms command execution and
a bug in the g++ compiler.
Comment 3 Gabriele Cosmo 2005-02-07 02:40:59 CET
Resolved by upgrading compiler. Problem closed.