Program: 118899
Project: 118899
Buggy source:
public void buildJob(String destinationPath,ProcessItem itemToExport,String version,String context,Map<ExportChoice,Object> exportChoiceMap,JobExportType jobExportType,IProgressMonitor monitor) throws Exception {
  IProgressMonitor pMonitor=new NullProgressMonitor();
  if (monitor != null) {
    pMonitor=monitor;
  }
  int scale=1000;
  int total=3;
  pMonitor.beginTask(Messages.getString("String_Node_Str",jobExportType),scale * total);
  ProcessItem processItem=itemToExport;
  if (!RelationshipItemBuilder.LATEST_VERSION.equals(version) && version != null && !"String_Node_Str".equals(version) && !version.equals(processItem.getProperty().getVersion())) {
    processItem=ItemCacheManager.getProcessItem(processItem.getProperty().getId(),version);
  }
  IBuildJobHandler buildJobHandler=BuildJobFactory.createBuildJobHandler(processItem,context,version,exportChoiceMap,jobExportType);
  buildJobHandler.generateItemFiles(true,new SubProgressMonitor(pMonitor,scale));
  buildJobHandler.generateJobFiles(new SubProgressMonitor(pMonitor,scale));
  String label=processItem.getProperty().getLabel();
  pMonitor.setTaskName(Messages.getString("String_Node_Str",label));
  buildJobHandler.build(new SubProgressMonitor(pMonitor,scale));
  IFile jobTargetFile=buildJobHandler.getJobTargetFile();
  if (jobTargetFile != null && jobTargetFile.exists()) {
    String zipPath=jobTargetFile.getLocation().toPortableString();
    if (needClasspathJar(exportChoiceMap)) {
      ExportJobUtil.deleteTempFiles();
      JavaJobExportReArchieveCreator creator=new JavaJobExportReArchieveCreator(zipPath,label);
      FilesUtils.unzip(jobTargetFile.getLocation().toPortableString(),creator.getTmpFolder() + File.separator + label+ "String_Node_Str"+ version);
      creator.buildNewJar();
      ZipToFile.zipFile(creator.getTmpFolder(),destinationPath);
      creator.deleteTempFiles();
    }
 else {
      File jobFileSource=new File(jobTargetFile.getLocation().toFile().getAbsolutePath());
      File jobFileTarget=new File(destinationPath);
      if (jobFileTarget.isDirectory()) {
        jobFileTarget=new File(destinationPath,jobFileSource.getName());
      }
      FilesUtils.copyFile(jobFileSource,jobFileTarget);
    }
  }
  pMonitor.worked(scale);
  pMonitor.done();
}

Fixed version (ground truth):
public void buildJob(String destinationPath,ProcessItem itemToExport,String version,String context,Map<ExportChoice,Object> exportChoiceMap,JobExportType jobExportType,IProgressMonitor monitor) throws Exception {
  IProgressMonitor pMonitor=new NullProgressMonitor();
  if (monitor != null) {
    pMonitor=monitor;
  }
  int scale=1000;
  int total=3;
  pMonitor.beginTask(Messages.getString("String_Node_Str",jobExportType),scale * total);
  ProcessItem processItem=itemToExport;
  if (!RelationshipItemBuilder.LATEST_VERSION.equals(version) && version != null && !"String_Node_Str".equals(version) && !version.equals(processItem.getProperty().getVersion())) {
    processItem=ItemCacheManager.getProcessItem(processItem.getProperty().getId(),version);
  }
  IBuildJobHandler buildJobHandler=BuildJobFactory.createBuildJobHandler(processItem,context,version,exportChoiceMap,jobExportType);
  buildJobHandler.generateItemFiles(true,new SubProgressMonitor(pMonitor,scale));
  buildJobHandler.generateJobFiles(new SubProgressMonitor(pMonitor,scale));
  String label=processItem.getProperty().getLabel();
  pMonitor.setTaskName(Messages.getString("String_Node_Str",label));
  buildJobHandler.build(new SubProgressMonitor(pMonitor,scale));
  IFile jobTargetFile=buildJobHandler.getJobTargetFile();
  if (jobTargetFile != null && jobTargetFile.exists()) {
    IPath jobZipLocation=jobTargetFile.getLocation();
    File jobZipFile=jobZipLocation.toFile();
    String jobZip=jobZipLocation.toString();
    if (needClasspathJar(exportChoiceMap)) {
      ExportJobUtil.deleteTempFiles();
      JavaJobExportReArchieveCreator creator=new JavaJobExportReArchieveCreator(jobZip,label);
      FilesUtils.unzip(jobZip,creator.getTmpFolder() + File.separator + label+ "String_Node_Str"+ version);
      creator.buildNewJar();
      ZipToFile.zipFile(creator.getTmpFolder(),jobZip);
      creator.deleteTempFiles();
    }
    BDJobReArchieveCreator bdRecreator=new BDJobReArchieveCreator(processItem);
    bdRecreator.create(jobZipFile);
    File jobFileTarget=new File(destinationPath);
    if (jobFileTarget.isDirectory()) {
      jobFileTarget=new File(destinationPath,jobZipFile.getName());
    }
    FilesUtils.copyFile(jobZipFile,jobFileTarget);
  }
  pMonitor.worked(scale);
  pMonitor.done();
}