RE: [ROOT] bug in TTree::Fill

From: Philippe Canal (pcanal@fnal.gov)
Date: Wed Sep 04 2002 - 16:51:09 MEST


Hi Andrej,

Thanks for noting this problem.  The proper fix is pending being checked-in
the CVS repository.  Note that your proposed fix is incomplete since
fDirectory can also be null.

Cheers,
Philippe.

-----Original Message-----
From: owner-roottalk@pcroot.cern.ch
[mailto:owner-roottalk@pcroot.cern.ch]On Behalf Of Andrej Filipcic
Sent: Wednesday, September 04, 2002 2:33 AM
To: roottalk@pcroot.cern.ch
Subject: [ROOT] bug in TTree::Fill



Hi,

there is a bug in rootcvs in TTree::Fill function. Fill crashes if there
is no TFile used. The line tree/src/TTree.cxx:2000

	if (!fDirectory) return nbytes;

should be modified to

	if (!fDirectory->GetFile()) return nbytes;

Andrej

--
_____________________________________________________________
   doc. dr. Andrej Filipcic,   E-mail: Andrej.Filipcic@ijs.si
   Department of Experimental High Energy Physics - F9
   Jozef Stefan Institute, Jamova 39, P.o.Box 3000
   SI-1001 Ljubljana, Slovenia
   Tel.: +386-1-477-3674    Fax: +386-1-425-7074
-------------------------------------------------------------



This archive was generated by hypermail 2b29 : Sat Jan 04 2003 - 23:51:07 MET