]> git.uio.no Git - u/mrichter/AliRoot.git/blobdiff - MUON/AliMUONTriggerSubprocessor.cxx
dEdxSSDAQA added to PilotAnalysis
[u/mrichter/AliRoot.git] / MUON / AliMUONTriggerSubprocessor.cxx
index e9add74d751cb8776fe9df8baa7d38ab927be01a..bea01143d26e214e171d04fec2e3143b191ca61b 100644 (file)
@@ -84,7 +84,7 @@ AliMUONTriggerSubprocessor::GetFileName(const char* fid) const
 }
 
 //_____________________________________________________________________________
-void 
+Bool_t 
 AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTime)
 {
   /// When starting a new run, reads in the trigger online files.
@@ -114,7 +114,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi
   {
     Master()->Log("FATAL ERROR : DA does not seem to have been run !!!");
     Master()->Invalidate();
-    return;
+    return kFALSE;
   }
   
   // OK. We have an exportedFiles.dat file at hand.
@@ -128,6 +128,11 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi
   WhichFilesToRead(GetFileName("EXPORTED").Data(),
                    globalFile,regionalFile,localFile,lutFile);
   
+  if ((globalFile+regionalFile+localFile+lutFile) == 0) {
+    Master()->Log("No file(s) to be processed for this run. Exiting.");
+    return kTRUE;
+  }
+  
   delete fRegionalConfig; fRegionalConfig = 0x0;
   delete fLocalMasks; fLocalMasks = 0x0;
   delete fGlobalConfig; fGlobalConfig = 0x0;
@@ -146,7 +151,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi
   {
     Master()->Log("Could not read some input file(s). Aborting");
     Master()->Invalidate();
-    return;
+    return kFALSE;
   }
   
   if ( regionalFile ) fRegionalConfig = new AliMUONRegionalTriggerConfig();
@@ -155,9 +160,9 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi
 
   AliMUONTriggerIO tio;
   
-  Bool_t ok = tio.ReadConfig(GetFileName("LOCAL").Data(),
-                             GetFileName("REGIONAL").Data(),
-                             GetFileName("GLOBAL").Data(),
+  Bool_t ok = tio.ReadConfig(localFile ? GetFileName("LOCAL").Data() : "",
+                             regionalFile ? GetFileName("REGIONAL").Data() : "",
+                             globalFile ? GetFileName("GLOBAL").Data() : "",
                              fLocalMasks,fRegionalConfig,fGlobalConfig);
   
   if (!ok)
@@ -187,6 +192,7 @@ AliMUONTriggerSubprocessor::Initialize(Int_t run, UInt_t startTime, UInt_t endTi
       fLUT = 0x0;
     }
   }
+  return kTRUE;
 }
 
 //_____________________________________________________________________________