Program: 56343
Project: 56343
Buggy source:
@Exported public List<Component> getPipelines(){
  try {
    LOG.fine("String_Node_Str");
    List<Component> components=new ArrayList<Component>();
    if (componentSpecs != null) {
      for (      ComponentSpec componentSpec : componentSpecs) {
        AbstractProject firstJob=ProjectUtil.getProject(componentSpec.getFirstJob(),getOwnerItemGroup());
        AbstractProject lastJob=ProjectUtil.getProject(componentSpec.getLastJob(),getOwnerItemGroup());
        if (firstJob != null) {
          components.add(getComponent(componentSpec.getName(),firstJob,lastJob,showAggregatedPipeline));
        }
 else {
          throw new PipelineException("String_Node_Str" + componentSpec.getFirstJob());
        }
      }
    }
    if (regexpFirstJobs != null) {
      for (      RegExpSpec regexp : regexpFirstJobs) {
        Map<String,AbstractProject> matches=ProjectUtil.getProjects(regexp.getRegexp());
        for (        Map.Entry<String,AbstractProject> entry : matches.entrySet()) {
          components.add(getComponent(entry.getKey(),entry.getValue(),null,showAggregatedPipeline));
        }
      }
    }
    if (getSorting() != null && !getSorting().equals(NONE_SORTER)) {
      ComponentComparatorDescriptor comparatorDescriptor=ComponentComparator.all().find(sorting);
      if (comparatorDescriptor != null) {
        Collections.sort(components,comparatorDescriptor.createInstance());
      }
    }
    LOG.fine("String_Node_Str" + components);
    error=null;
    for (int i=0; i < components.size(); i++) {
      components.get(i).setComponentNumber(i + 1);
    }
    return components;
  }
 catch (  PipelineException e) {
    error=e.getMessage();
    return new ArrayList<Component>();
  }
}

Fixed version (ground truth):
@Exported public List<Component> getPipelines(){
  try {
    LOG.fine("String_Node_Str");
    List<Component> components=new ArrayList<Component>();
    if (componentSpecs != null) {
      for (      ComponentSpec componentSpec : componentSpecs) {
        AbstractProject firstJob=ProjectUtil.getProject(componentSpec.getFirstJob(),getOwnerItemGroup());
        AbstractProject lastJob=ProjectUtil.getProject(componentSpec.getLastJob(),getOwnerItemGroup());
        if (firstJob != null) {
          components.add(getComponent(componentSpec.getName(),firstJob,lastJob,showAggregatedPipeline,(componentSpecs.indexOf(componentSpec) + 1)));
        }
 else {
          throw new PipelineException("String_Node_Str" + componentSpec.getFirstJob());
        }
      }
    }
    if (regexpFirstJobs != null) {
      for (      RegExpSpec regexp : regexpFirstJobs) {
        Map<String,AbstractProject> matches=ProjectUtil.getProjects(regexp.getRegexp());
        int index=1;
        for (        Map.Entry<String,AbstractProject> entry : matches.entrySet()) {
          components.add(getComponent(entry.getKey(),entry.getValue(),null,showAggregatedPipeline,index));
          index++;
        }
      }
    }
    if (getSorting() != null && !getSorting().equals(NONE_SORTER)) {
      ComponentComparatorDescriptor comparatorDescriptor=ComponentComparator.all().find(sorting);
      if (comparatorDescriptor != null) {
        Collections.sort(components,comparatorDescriptor.createInstance());
      }
    }
    LOG.fine("String_Node_Str" + components);
    error=null;
    return components;
  }
 catch (  PipelineException e) {
    error=e.getMessage();
    return new ArrayList<Component>();
  }
}