Program: 122366
Project: 122366
Buggy source:
@Override public List<ExportFileResource> getExportResources(ExportFileResource[] processes,String... codeOptions) throws ProcessorException {
  List<ExportFileResource> list=new ArrayList<ExportFileResource>();
  ExportFileResource osgiResource=new ExportFileResource(null,"String_Node_Str");
  ExportFileResource jobScriptResource=new ExportFileResource(null,"String_Node_Str");
  List<ProcessItem> itemToBeExport=new ArrayList<ProcessItem>();
  list.add(osgiResource);
  list.add(jobScriptResource);
  ProcessorUtilities.setExportConfig(JAVA,"String_Node_Str","String_Node_Str");
  try {
    for (    ExportFileResource process : processes) {
      ProcessItem processItem=(ProcessItem)process.getItem();
      if (processItem.eIsProxy() || processItem.getProcess().eIsProxy()) {
        try {
          Property property=ProxyRepositoryFactory.getInstance().getUptodateProperty(processItem.getProperty());
          processItem=(ProcessItem)property.getItem();
        }
 catch (        PersistenceException e) {
          throw new ProcessorException(e);
        }
      }
      itemToBeExport.add(processItem);
      jobName=processItem.getProperty().getLabel();
      jobClassName=getPackageName(processItem) + PACKAGE_SEPARATOR + jobName;
      jobVersion=processItem.getProperty().getVersion();
      if (!isMultiNodes() && getSelectedJobVersion() != null) {
        jobVersion=getSelectedJobVersion();
      }
      ERepositoryObjectType type=ERepositoryObjectType.getItemType(processItem);
      if (type.equals(ERepositoryObjectType.PROCESS)) {
        itemType=JOB;
      }
 else {
        itemType=ROUTE;
      }
      String libPath=calculateLibraryPathFromDirectory(process.getDirectoryName());
      String standardJars=libPath + PATH_SEPARATOR + SYSTEMROUTINE_JAR+ ProcessorUtilities.TEMP_JAVA_CLASSPATH_SEPARATOR+ libPath+ PATH_SEPARATOR+ USERROUTINE_JAR+ ProcessorUtilities.TEMP_JAVA_CLASSPATH_SEPARATOR+ PACKAGE_SEPARATOR;
      ProcessorUtilities.setExportConfig(JAVA,standardJars,libPath);
      String processId=processItem.getProperty().getId();
      if (!isOptionChoosed(ExportChoice.doNotCompileCode)) {
        generateJobFiles(processItem,contextName,jobVersion,statisticPort != IProcessor.NO_STATISTICS,tracePort != IProcessor.NO_TRACES,isOptionChoosed(ExportChoice.applyToChildren),true,progressMonitor);
        analysisModules(processId,jobVersion);
      }
 else {
        LastGenerationInfo.getInstance().setModulesNeededWithSubjobPerJob(processId,jobVersion,Collections.<ModuleNeeded>emptySet());
        LastGenerationInfo.getInstance().setLastMainJob(null);
      }
      getJobScriptsUncompressed(jobScriptResource,processItem);
      addXmlMapping(process,isOptionChoosed(ExportChoice.needSourceCode));
      if (JOB.equals(itemType) && (null != getRESTRequestComponent(processItem))) {
        osgiResource.addResources(getMetaInfSpringFolder(),Collections.singletonList(generateRestJobSpringFiles(processItem)));
      }
 else {
        osgiResource.addResources(getOSGIInfFolder(),Collections.singletonList(generateBlueprintConfig(processItem)));
      }
      if (ROUTE.equals(itemType)) {
        addOSGIRouteResources(osgiResource,processItem);
      }
    }
    ExportFileResource libResource=getCompiledLibExportFileResource(processes);
    if (libResource != null) {
      list.add(libResource);
    }
    ExportFileResource providedLibResources=getProvidedLibExportFileResource(processes);
    if (providedLibResources != null) {
      list.add(providedLibResources);
    }
    ExportFileResource metaInfoFolder=genMetaInfoFolder(libResource,itemToBeExport);
    list.add(0,metaInfoFolder);
  }
 catch (  IOException e) {
    throw new ProcessorException(e);
  }
  return list;
}

Fixed version (ground truth):
@Override public List<ExportFileResource> getExportResources(ExportFileResource[] processes,String... codeOptions) throws ProcessorException {
  List<ExportFileResource> list=new ArrayList<ExportFileResource>();
  ExportFileResource osgiResource=new ExportFileResource(null,"String_Node_Str");
  ExportFileResource jobScriptResource=new ExportFileResource(null,"String_Node_Str");
  List<ProcessItem> itemToBeExport=new ArrayList<ProcessItem>();
  list.add(osgiResource);
  list.add(jobScriptResource);
  ProcessorUtilities.setExportConfig(JAVA,"String_Node_Str","String_Node_Str");
  try {
    for (    ExportFileResource process : processes) {
      ProcessItem processItem=(ProcessItem)process.getItem();
      if (processItem.eIsProxy() || processItem.getProcess().eIsProxy()) {
        try {
          Property property=ProxyRepositoryFactory.getInstance().getUptodateProperty(processItem.getProperty());
          processItem=(ProcessItem)property.getItem();
        }
 catch (        PersistenceException e) {
          throw new ProcessorException(e);
        }
      }
      itemToBeExport.add(processItem);
      jobName=processItem.getProperty().getLabel();
      jobClassName=getPackageName(processItem) + PACKAGE_SEPARATOR + jobName;
      jobVersion=processItem.getProperty().getVersion();
      if (!isMultiNodes() && getSelectedJobVersion() != null) {
        jobVersion=getSelectedJobVersion();
      }
      ERepositoryObjectType type=ERepositoryObjectType.getItemType(processItem);
      if (type.equals(ERepositoryObjectType.PROCESS)) {
        itemType=JOB;
      }
 else {
        itemType=ROUTE;
      }
      String libPath=calculateLibraryPathFromDirectory(process.getDirectoryName());
      String standardJars=libPath + PATH_SEPARATOR + SYSTEMROUTINE_JAR+ ProcessorUtilities.TEMP_JAVA_CLASSPATH_SEPARATOR+ libPath+ PATH_SEPARATOR+ USERROUTINE_JAR+ ProcessorUtilities.TEMP_JAVA_CLASSPATH_SEPARATOR+ PACKAGE_SEPARATOR;
      ProcessorUtilities.setExportConfig(JAVA,standardJars,libPath);
      String processId=processItem.getProperty().getId();
      if (!isOptionChoosed(ExportChoice.doNotCompileCode)) {
        generateJobFiles(processItem,contextName,jobVersion,statisticPort != IProcessor.NO_STATISTICS,tracePort != IProcessor.NO_TRACES,isOptionChoosed(ExportChoice.applyToChildren),true,progressMonitor);
        analysisModules(processId,jobVersion);
      }
 else {
        LastGenerationInfo.getInstance().setModulesNeededWithSubjobPerJob(processId,jobVersion,Collections.<ModuleNeeded>emptySet());
        LastGenerationInfo.getInstance().setLastMainJob(null);
      }
      analysisMavenModule(processItem);
      getJobScriptsUncompressed(jobScriptResource,processItem);
      addXmlMapping(process,isOptionChoosed(ExportChoice.needSourceCode));
      if (JOB.equals(itemType) && (null != getRESTRequestComponent(processItem))) {
        osgiResource.addResources(getMetaInfSpringFolder(),Collections.singletonList(generateRestJobSpringFiles(processItem)));
      }
 else {
        osgiResource.addResources(getOSGIInfFolder(),Collections.singletonList(generateBlueprintConfig(processItem)));
      }
      if (ROUTE.equals(itemType)) {
        addOSGIRouteResources(osgiResource,processItem);
      }
    }
    ExportFileResource libResource=getCompiledLibExportFileResource(processes);
    if (libResource != null) {
      list.add(libResource);
    }
    ExportFileResource providedLibResources=getProvidedLibExportFileResource(processes);
    if (providedLibResources != null) {
      list.add(providedLibResources);
    }
    ExportFileResource metaInfoFolder=genMetaInfoFolder(libResource,itemToBeExport);
    list.add(0,metaInfoFolder);
  }
 catch (  IOException e) {
    throw new ProcessorException(e);
  }
  return list;
}