Test on PHOSloader existence added to destr.
authorschutz <schutz@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 29 Sep 2004 09:38:15 +0000 (09:38 +0000)
committerschutz <schutz@f7af4fe6-9843-0410-8265-dc069ae4e863>
Wed, 29 Sep 2004 09:38:15 +0000 (09:38 +0000)
PHOS/AliPHOSPID.cxx
PHOS/AliPHOSTrackSegmentMaker.cxx

index d4e02e75e8f4011cee267d4671ad0380762d29c8..4d64c1d1109b67ac416a6a3a6a8901d93891da61 100644 (file)
@@ -62,6 +62,7 @@ AliPHOSPID::~AliPHOSPID()
 {
   // dtor
  //Remove this from the parental task before destroying
-  AliPHOSGetter::Instance()->PhosLoader()->CleanPIDTask();
+  if(AliPHOSGetter::Instance()->PhosLoader())
+    AliPHOSGetter::Instance()->PhosLoader()->CleanPIDTask();
 }
 
index 39851c45b7a26835108843d272b2bcc0b664b019..0f3ea3b29be51bd3f7d83d5f3a79d779827848fc 100644 (file)
@@ -56,6 +56,7 @@ AliPHOSTrackSegmentMaker::AliPHOSTrackSegmentMaker(const TString alirunFileName,
 AliPHOSTrackSegmentMaker::~AliPHOSTrackSegmentMaker()
 {
  //Remove this from the parental task before destroying
-  AliPHOSGetter::Instance()->PhosLoader()->CleanTracker();
+  if(AliPHOSGetter::Instance()->PhosLoader())
+    AliPHOSGetter::Instance()->PhosLoader()->CleanTracker();
 }