Message: Re: How to find out segmentation error in this case? Not Logged In (login)
 Next-in-Thread Next-in-Thread
 Next-in-Forum Next-in-Forum

None Re: How to find out segmentation error in this case? 

Forum: Particles
Re: None How to find out segmentation error in this case? (long)
Re: None Re: How to find out segmentation error in this case? (Vladimir IVANTCHENKO )
Re: None Re: How to find out segmentation error in this case? (long)
Date: 19 Dec, 2006
From: Vladimir IVANTCHENKO <vnivanch@mail.cern.ch>

On Mon, 18 Dec 2006, long wrote:

> *** Discussion title: Particles
> Email replies to PublicHyperNews@slac.stanford.edu must include:
>   In-Reply-To: <"/particles/309/1/1"@geant4-hn.slac.stanford.edu>
>   Subject: ...change this to be about your reply.
> 
> Thank you, Vladimir. Could give me more detailed explains? In this case
> ,when I tried to use gdb, I alway got something like this:
> 
> 0x4359d0cf in malloc_consolidate () from /lib/libc.so.6
> 
> #1  0x4359ec3e in _int_free () from /lib/libc.so.6
> #2  0x435a2550 in free () from /lib/libc.so.6
> #3  0x441a8871 in operator delete () from /usr/lib/libstdc++.so.6
> #4  0x082e7a99 in ~G4NistManager (this=0x84c50c0) at src/G4NistManager.cc:100
> #5  0x082e7b18 in __tcf_0 () at src/G4NistManager.cc:67
> #6  0x43564939 in exit () from /lib/libc.so.6
> #7  0x4354ef34 in __libc_start_main () from /lib/libc.so.6
> #8  0x08055921 in _start ()
> 
>   I don't know how to find bug from these. Any suggestion? Thank you!
>  

Hello Long,

Be sure that you do not remove materials in your DetectorConstruction. 
If you create materials via 

G4Material* mymat = new G4Material(....);

do not delete mymat in the destructor.
If you include materials as an object:

G4Material  mymat;

Replace this by 

G4Material* mymat;

VI

Inline Depth:
 1 1
 All All
Outline Depth:
 1 1
 2 2
 All All
Add message: (add)

 Add Message Add Message
to: "Re: How to find out segmentation error in this case?"

 Subscribe Subscribe

This site runs SLAC HyperNews version 1.11-slac-98, derived from the original HyperNews


[ Geant 4 Home | Geant 4 HyperNews | Search | Request New Forum | Feedback ]