]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Protection against nonexisting input tree
authorkowal2 <kowal2@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 9 May 2002 06:57:09 +0000 (06:57 +0000)
committerkowal2 <kowal2@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 9 May 2002 06:57:09 +0000 (06:57 +0000)
TPC/AliTPCclusterer.cxx

index e7a0be29a2a1f8f1faf8bb08d2470466c6081529..a9275515ca67e0a64f4de9ff90411888883644e6 100644 (file)
@@ -15,6 +15,9 @@
 
 /*
 $Log$
+Revision 1.8  2002/03/29 06:57:45  kowal2
+Restored backward compatibility to use the hits from Dec. 2000 production.
+
 Revision 1.7  2001/10/21 19:04:55  hristov
 Several patches were done to adapt the barel reconstruction to the multi-event case. Some memory leaks were corrected. (Yu.Belikov)
 
@@ -137,6 +140,11 @@ void AliTPCclusterer::Digits2Clusters(const AliTPCParam *par, TFile *of, Int_t e
   }
   TTree *t = (TTree *)gDirectory->Get(dname);
 
+  if (!t) {
+    cerr<<"Input tree with "<<dname<<" not found"<<endl;
+    return;
+  }
+
   AliSimDigits digarr, *dummy=&digarr;
   t->GetBranch("Segment")->SetAddress(&dummy);
   Stat_t nentries = t->GetEntries();