]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - STEER/AliESDInputHandler.cxx
Coding rule violations fixed.
[u/mrichter/AliRoot.git] / STEER / AliESDInputHandler.cxx
index fe36dc1c64b9926fb8f235a7ec8865c170588c60..64326efda4a96c2fa6176accfdd6a8f647c459d8 100644 (file)
@@ -39,6 +39,7 @@
 #include "AliRunTag.h"
 #include "AliEventTag.h"
 #include "AliLog.h"
+#include "AliESDpid.h"
 
 ClassImp(AliESDInputHandler)
 
@@ -72,6 +73,7 @@ AliESDInputHandler::~AliESDInputHandler()
 {
   //  destructor
   if (fRunTag) delete fRunTag;
+  delete fESDpid;
 }
 
 //______________________________________________________________________________
@@ -379,7 +381,7 @@ Int_t AliESDInputHandler::GetNEventRejectedInFile()
 }
 
 //______________________________________________________________________________
-Bool_t AliESDInputHandler::GetCutSummaryForChain(Int_t *aTotal, Int_t *aAccepted, Int_t *aRejected)
+Bool_t AliESDInputHandler::GetCutSummaryForChain(Int_t *aTotal,  Int_t *aAccepted,  Int_t *aRejected)
 {
   // Get number of events in the full chain
   // Count accepted and rejected events
@@ -414,6 +416,7 @@ Bool_t AliESDInputHandler::GetCutSummaryForChain(Int_t *aTotal, Int_t *aAccepted
     
     Int_t iAcc = atoi(strtok(iTagInfo, ","));
     Int_t iRej = atoi(strtok(NULL, ","));
+    free(iTagInfo);
     
     iAccList += iAcc;
     iRejList += iRej;
@@ -463,7 +466,7 @@ Int_t AliESDInputHandler::GetNFilesEmpty()
     
     Int_t iAcc = atoi(strtok(iTagInfo, ","));
     Int_t iRej = atoi(strtok(NULL, ","));
-    
+    free(iTagInfo);
     if ((iAcc == 0) && ((iRej+iAcc)>0))
       iFilesEmpty++;
   }
@@ -484,3 +487,15 @@ TObject *AliESDInputHandler::GetStatistics(Option_t *option) const
    if (opt=="BIN0") return fEventCuts->GetStatistics("BIN0");
    else return fEventCuts->GetStatistics("ALL");
 }   
+
+//______________________________________________________________________________
+void AliESDInputHandler::CreatePIDResponse(Bool_t isMC/*=kFALSE*/)
+{
+  //
+  // create the pid response object if it does not exist yet
+  //
+  if (fESDpid) return;
+  fESDpid=new AliESDpid(isMC);
+
+}
+