]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - ITS/AliITSRawStreamSPDErrorLog.cxx
Added macro for SDD corection map and drift speed calibration (Ruben)
[u/mrichter/AliRoot.git] / ITS / AliITSRawStreamSPDErrorLog.cxx
index 437e48e02e1ac0799f297ad94c6d76365a93aeb5..a0af29b101cccc14991011117084f063409116df 100644 (file)
@@ -65,7 +65,9 @@ AliITSRawStreamSPDErrorLog::AliITSRawStreamSPDErrorLog(const AliITSRawStreamSPDE
       fConsErrPos[err][eq] = new TGraph(*logger.fConsErrPos[err][eq]);
     }
     fConsErrType[eq] = new TH1F(*logger.fConsErrType[eq]);
+    fConsErrType[eq]->SetDirectory(0);
     fConsErrFraction[eq] = new TH1F(*logger.fConsErrFraction[eq]);
+    fConsErrFraction[eq]->SetDirectory(0);
   }
   
 }
@@ -75,7 +77,9 @@ AliITSRawStreamSPDErrorLog& AliITSRawStreamSPDErrorLog::operator=(const AliITSRa
   if (this!=&logger) {
     delete fText;
     delete fTextTmpGeneral;
-    delete[] fTextTmp;
+    for(Int_t eq=0; eq<20;eq++){
+    delete fTextTmp[eq];
+    }
     this->DeleteHistograms();
 
     for (UInt_t eq=0; eq<20; eq++) {
@@ -104,7 +108,9 @@ AliITSRawStreamSPDErrorLog& AliITSRawStreamSPDErrorLog::operator=(const AliITSRa
        fConsErrPos[err][eq] = new TGraph(*logger.fConsErrPos[err][eq]);
       }
       fConsErrType[eq] = new TH1F(*logger.fConsErrType[eq]);
+      fConsErrType[eq]->SetDirectory(0);
       fConsErrFraction[eq] = new TH1F(*logger.fConsErrFraction[eq]);
+      fConsErrFraction[eq]->SetDirectory(0);
     }
 
   }
@@ -117,7 +123,9 @@ AliITSRawStreamSPDErrorLog::~AliITSRawStreamSPDErrorLog() {
   DeleteHistograms();
   delete fText;
   delete fTextTmpGeneral;
-  delete[] fTextTmp;
+  for(Int_t eq=0; eq<20; eq++){
+  delete fTextTmp[eq];
+  }
 }
 //________________________________________________________________________________________________
 void AliITSRawStreamSPDErrorLog::InitHistograms() {
@@ -127,12 +135,14 @@ void AliITSRawStreamSPDErrorLog::InitHistograms() {
     histName = Form("ConsErrType %d",eq);
     histTitle = Form("Distribution of errors, eq %d",eq);
     fConsErrType[eq]=new TH1F(histName.Data(),histTitle.Data(),kNrErrorCodes,-0.5,kNrErrorCodes-0.5);
+    fConsErrType[eq]->SetDirectory(0);
     fConsErrType[eq]->SetXTitle("Error Code");
     fConsErrType[eq]->SetYTitle("Nr Errors");
     
     histName = Form("ConsErrFraction %d",eq);
     histTitle = Form("Fraction of events with errors, eq %d",eq);
     fConsErrFraction[eq]=new TH1F(histName.Data(),histTitle.Data(),kNrErrorCodes,-0.5,kNrErrorCodes-0.5);
+    fConsErrFraction[eq]->SetDirectory(0);
     fConsErrFraction[eq]->SetXTitle("Error Code");
     fConsErrFraction[eq]->SetYTitle("Fraction");
     
@@ -147,7 +157,7 @@ void AliITSRawStreamSPDErrorLog::InitHistograms() {
   }
 }
 //________________________________________________________________________________________________
-void AliITSRawStreamSPDErrorLog::DeleteHistograms() const {
+void AliITSRawStreamSPDErrorLog::DeleteHistograms() {
   // delete histograms
   for (UInt_t eq=0; eq<20; eq++) {
     delete fConsErrType[eq];