Linear Collider Forum

Home » Software Tools » LCIO » Seg Fault when adding collections
Re: Seg Fault when adding collections [message #2212 is a reply to message #2206] Wed, 15 February 2012 09:15 Go to previous messageGo to previous message
Messages: 233
Registered: January 2004
Location: DESY, Hamburg
hi tony,

as far as I can see there are a few issues with your code:

- you should not use setsubset with collections of elements that you created -> this will result in corrupt LCIO files

- a memory leak in ee_Durham_Jet_Finder_Exclusive (l. 158):

you create a new particle on the heap every time you combine two particles but in the end you only add n jet particles to the collection
-> you need to delete the intermediate ReconstrucetParticles (possibly in CombineParticles)

- the follwoing will result in an undefined pointer in the LCIO file (if the vector is empty the first element is undefined):
      jet->addParticle( p1_particles[0] );

hope this helps to find your problem.

Cheers, Frank.
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Read Message
Previous Topic:LCIO Wiki
Next Topic:Request: addition of "quality" word to TrackerData
Goto Forum:

Current Time: Thu Oct 17 06:23:51 Pacific Daylight Time 2019
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.1.
Copyright ©2001-2010 FUDforum Bulletin Board Software