]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Reset ESDfriend after event loop
authorkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 11 Jul 2007 14:07:55 +0000 (14:07 +0000)
committerkleinb <kleinb@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 11 Jul 2007 14:07:55 +0000 (14:07 +0000)
STEER/AliReconstruction.cxx

index 95cc72da82c7754e208e3357cc7bdb11493f136e..99d202cbffa6a8b16fa382669740b8116d5724ed 100644 (file)
@@ -596,6 +596,9 @@ Bool_t AliReconstruction::Run(const char* input)
   esd = NULL; hltesd = NULL;
   */
   // create the branch with ESD additions
+
+
+
   AliESDfriend *esdf = 0; 
   if (fWriteESDfriend) {
     esdf = new AliESDfriend();
@@ -603,6 +606,7 @@ Bool_t AliReconstruction::Run(const char* input)
     br->SetFile("AliESDfriends.root");
     esd->AddObject(esdf);
   }
+
   
   // Get the diamond profile from OCDB
   AliCDBEntry* entry = AliCDBManager::Instance()
@@ -778,11 +782,16 @@ Bool_t AliReconstruction::Run(const char* input)
     if (fCheckPointLevel > 0)  WriteESD(esd, "final"); 
     esd->Reset();
     hltesd->Reset();
+    if (fWriteESDfriend) {
+      new (esdf) AliESDfriend(); // Reset...
+    }
     // esdf->Reset();
     // delete esdf; esdf = 0;
   } 
 
 
+
+
   tree->GetUserInfo()->Add(esd);
   hlttree->GetUserInfo()->Add(hltesd);