RE: Destructor problems

From: Manuel Mussini <Manuel.Mussini_at_bo.infn.it>
Date: Mon, 8 Oct 2007 17:16:10 +0200


I've solved the problem!
A data member was declared to be an array [3][3] but it was filled as [5][5].
It's not clear to me what was wrong in the destructor (there should have been an out of index error ... I think) but filling it in the correct way everything works fine!

Bye...

> -----Original Message-----
> From: Manuel Mussini [mailto:mussini_at_bo.infn.it]
> Sent: Monday, October 08, 2007 15:27
> To: 'roottalk_at_root.cern.ch'
> Subject: RE: [ROOT] Destructor problems
>
> That's the problem! :-)
> I'm running under a CDF environment so the answer is no! :-(
> Many data members point to CDF classes!
> In addition to that I'm getting errors using gdb because some libraries
> (FORTRAN) are not recognised! :-(
> This is why I'm asking for ANY idea!
> I'm completely lost! :-)))
>
> Only 3 things are sure:
> - it crashes at the first delete occurrence
> - the TV0 instance is correctly created
> - the job runs if I remove the delete but obviously dies because the
> instances rapidly fill up the memory
>
> This is why I'm quite sure that it's something related to the dtor!
>
> Bye...
>
>
>
> > -----Original Message-----
> > From: Rene Brun [mailto:Rene.Brun_at_cern.ch]
> > Sent: Monday, October 08, 2007 15:05
> > To: Manuel Mussini
> > Cc: roottalk_at_lxbuild091.cern.ch
> > Subject: Re: [ROOT] Destructor problems
> >
> > Could you send the shortest but RUNNING files TV.h and TV.cxx that we
> > can use to understand your problem?
> >
> > Rene brun
> >
> > Manuel Mussini wrote:
> > > Hi all,
> > > I made a class called TV0 to store some results from a fit but I'm
> > > experiencing some problems with it's destructor.
> > > When I use it, I create a TV0 *tmpV0 = new TV0() and if some cuts are
> > not
> > > passed I delete the new instance (delete tmpV0).
> > > ROOT crashes with a segmentation violation referring to the dtor:
> > >
> > > 0x04e6f1ce in TV0::~TV0 [in-charge deleting]() at
> > > /home/mussini/Run2Analysis/K0sL0/TV0.hh:57 from
> > > /home/mussini/Run2Analysis/K0sL0/TV0_cc.so
> > >
> > > I tried several ways to fix this issue but without succeeding! Inside
> > the
> > > class no "new" instances are created so the destructor is simply:
> > > ~TV0() {}
> > >
> > > I know that these few infos could not be enough to understand the
> > problem
> > > but ... any idea about where can I start looking at? There could be a
> > BIG
> > > and obvious mistake that I'm not able to find! :-)))
> > > I've attached the class interface.
> > >
> > > Bye...
> > >
Received on Mon Oct 08 2007 - 17:16:42 CEST

This archive was generated by hypermail 2.2.0 : Mon Oct 08 2007 - 23:50:01 CEST