Memory leak fixed (L. Molnar)
authorgvolpe <gvolpe@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 16 Nov 2011 15:02:54 +0000 (15:02 +0000)
committergvolpe <gvolpe@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 16 Nov 2011 15:02:54 +0000 (15:02 +0000)
HMPID/AliHMPIDQAChecker.cxx

index e869108..5359067 100644 (file)
@@ -45,8 +45,8 @@ ClassImp(AliHMPIDQAChecker)
  //_________________________________________________________________
 AliHMPIDQAChecker::AliHMPIDQAChecker() : 
 AliQACheckerBase("HMPID","HMPID Quality Assurance Data Checker"), 
-fNoReference(kTRUE), 
-fQARefRec(NULL)
+fNoReference(kTRUE)
+//fQARefRec(NULL)
 {
     //ctor, fetches the reference data from OCDB 
   char * detOCDBDir = Form("HMPID/%s/%s", AliQAv1::GetRefOCDBDirName(), AliQAv1::GetRefDataDirName()) ; 
@@ -78,8 +78,7 @@ fQARefRec(NULL)
 //_________________________________________________________________
 AliHMPIDQAChecker::~AliHMPIDQAChecker() 
 {
-  fQARefRec->Delete() ; 
-  delete fQARefRec ; 
+  if(fQARefRec) { fQARefRec->Delete() ;   delete fQARefRec ; }
 }
 //_________________________________________________________________
 void AliHMPIDQAChecker::Check(Double_t *  check, AliQAv1::ALITASK_t index, TObjArray ** list, const AliDetectorRecoParam * /*recoParam*/)