+//______________________________________________________________________________________________
+void AliShuttleTrigger::CheckTerminate()
+{
+ //
+ // Checks if the Shuttle got an external terminate request by a created file
+ // This is an alternative to the signal which causes problems with the API libraries
+ //
+
+ if (strlen(fConfig->GetTerminateFilePath()) == 0)
+ return;
+
+ if (gSystem->AccessPathName(fConfig->GetTerminateFilePath()) == kFALSE)
+ {
+ AliInfo("Terminate file exists. Terminating Shuttle...");
+ fTerminate = kTRUE;
+ }
+}
+