Fix against cleaning with deletion of fToFit in destructor
authorprsnko <prsnko@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 10 Jan 2012 18:43:57 +0000 (18:43 +0000)
committerprsnko <prsnko@f7af4fe6-9843-0410-8265-dc069ae4e863>
Tue, 10 Jan 2012 18:43:57 +0000 (18:43 +0000)
PHOS/AliPHOSRawFitterv4.cxx

index 2231168..d18d800 100644 (file)
@@ -159,15 +159,14 @@ Bool_t AliPHOSRawFitterv4::Eval(const UShort_t *signal, Int_t sigStart, Int_t si
       fSampleParamsLow->AddAt(pedestal,4) ;
       fSampleParamsLow->AddAt(double(maxSample),5) ;
       fSampleParamsLow->AddAt(double(iStart),6) ;
-      fToFit->AddFirst((TObject*)fSampleParamsLow) ; 
     }
     else if (fCaloFlag == 1){ // High gain
       fSampleParamsHigh->AddAt(pedestal,4) ;
       fSampleParamsHigh->AddAt(double(maxSample),5) ;
       fSampleParamsHigh->AddAt(double(iStart),6) ;
-      fToFit->AddFirst((TObject*)fSampleParamsHigh) ; 
     }
     result=EvalWithFitting(samples,times); 
+    fToFit->Clear("nodelete") ;
     delete samples ;
     delete times ;