- AliHLTModuleAgent* pAgent=AliHLTModuleAgent::GetFirstAgent();
- while (pAgent && iResult>=0) {
- if (blackList) {
- int i=0;
- for (; i<size; i++) {
- if (blackList[i]==pAgent) break;
+ vector<AliHLTModuleAgent*> agents;
+ for (AliHLTModuleAgent* pAgent=AliHLTModuleAgent::GetFirstAgent();
+ pAgent && iResult>=0;
+ pAgent=AliHLTModuleAgent::GetNextAgent()) {
+
+ // check if we found the agent for the specified library
+ if (library) {
+ TString check="libAliHLT"; check+=pAgent->GetModuleId();
+ if (check.CompareTo(library)==0) {
+ agents.clear();
+ agents.push_back(pAgent);
+ break;