Hello Ed, 2 more questions: - Are you running in batch mode? Do you have any open canvas at the time you are processing your files. - Did you link against of libNew.lib? Thank you. Valeri > -----Original Message----- > From: Ed Oltman [mailto:eoltman@imago.com] > Sent: Tuesday, July 08, 2003 9:43 PM > To: Roottalk@Pcroot. Cern. Ch > Subject: [ROOT] deletion of a TProfile object crashes in Win2k. > > Hello, > > I have a dll built with win32 root version 3.05/5 that opens and > processes > several root file in sequence. The root file contains an object > containing a TProfile > member: > > TProfile *fVoltProf; > > This object is read from an input with objects (costumized) > Streamer(): > > R__b >> fVoltProfile; if (fVoltProfile) > fVoltProfile->SetDirectory(0) > > When the second file is opened, this object's dtor is called. The > following > line causes a crash (access violation) when the member's > fFunction->Delete() is called in TH1::~TH1(): > > delete fVoltProfile; > > fVoltProfile->fFunctions has two items: The first is a TF1 object that > is deleted > just fine. The second is a TPaveStats and thats what causes the crash. > The > stack is shown starting from when my TProfile is deleted... > > > 00ff035b() > TList::Remove(TObject * 0x024755c8) line 551 + 16 bytes > TCollection::RecursiveRemove(TObject * 0x024755c8) line 283 + 18 bytes > TPaveStats::~TPaveStats() line 88 > LIBGRAF! TPaveStats::`vector deleting destructor'(unsigned int) + 84 > bytes > TCollection::GarbageCollect(TObject * 0x024755c8) line 415 + 31 bytes > TList::Delete(const char * 0x00ba4f3c) line 386 + 14 bytes > TH1::~TH1() line 472 > TH1D::~TH1D() line 6068 + 50 bytes > TProfile::~TProfile() line 78 + 29 bytes > LIBHIST! TProfile::`vector deleting destructor'(unsigned int) + 84 bytes > CVoltage::~CVoltage() line 40 + 45 bytes <-- This is where delete > fVoltProfile occurs > > Note 0: I am running on Win2k > > Note 1: this crash only occurs when I run my dll in the debugger. The > crash only occurs > when I debug the DLL from visual v++6. If I simply run the debug > version, it does not > crash. > > Note 2: I build the root libraries using cygwin+make+visual c++ 6 so > that I don't rely > on the .net libraries. I used the sources from > root_v3.05.05.source.tar.gz on root > website. > > Any help on this problem would be greatly appreciated - thank you.. > > Ed Oltman
This archive was generated by hypermail 2b29 : Thu Jan 01 2004 - 17:50:13 MET