Fix to avoid deleting cached CDB objects - modified fix by Peter.
authorcholm <cholm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 3 Oct 2011 07:25:22 +0000 (07:25 +0000)
committercholm <cholm@f7af4fe6-9843-0410-8265-dc069ae4e863>
Mon, 3 Oct 2011 07:25:22 +0000 (07:25 +0000)
FMD/AliFMDParameters.cxx

index ac1e74d..7142e26 100644 (file)
@@ -744,7 +744,9 @@ AliFMDParameters::InitZeroSuppression(AliFMDPreprocessor* pp)
   if (!fZeroSuppression->Ptr()) {
     AliWarningF("Empty zero suppression object from CDB, assuming %d",
                fFixedZeroSuppression);
-    delete fZeroSuppression;
+    AliCDBManager* cdbMan = AliCDBManager::Instance();
+    if(!cdbMan || !cdbMan->GetCacheFlag())
+      delete fZeroSuppression;
     fZeroSuppression = 0;
   }
 }