]> git.uio.no Git - u/mrichter/AliRoot.git/commitdiff
Close files before delete.
authormorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 13 Mar 2008 11:55:02 +0000 (11:55 +0000)
committermorsch <morsch@f7af4fe6-9843-0410-8265-dc069ae4e863>
Thu, 13 Mar 2008 11:55:02 +0000 (11:55 +0000)
STEER/AliMCEventHandler.cxx

index cf303c07fe43e2ad031146eccddb3628348880d6..20f007273fc6c92a445dd84dd9f46319f691cab6 100644 (file)
@@ -256,9 +256,9 @@ void AliMCEventHandler::ResetIO()
     delete fTreeE; fTreeE = 0;
 
 // Reset files
-    if (fFileE)  {delete fFileE;  fFileE  = 0;}
-    if (fFileK)  {delete fFileK;  fFileK  = 0;}
-    if (fFileTR) {delete fFileTR; fFileTR = 0;}
+    if (fFileE)  {fFileE->Close();  delete fFileE;  fFileE  = 0;}
+    if (fFileK)  {fFileK->Close();  delete fFileK;  fFileK  = 0;}
+    if (fFileTR) {fFileTR->Close(); delete fFileTR; fFileTR = 0;}
     fExtension="";
 }