Program: 126273
Project: 126273
Buggy source:
@SuppressWarnings("String_Node_Str") protected void addChildrenJobsInAssembly(IFile assemblyFile) throws Exception {
  if (!assemblyFile.exists()) {
    return;
  }
  final File file=assemblyFile.getLocation().toFile();
  DocumentBuilderFactory dbf=DocumentBuilderFactory.newInstance();
  DocumentBuilder db=dbf.newDocumentBuilder();
  Document document=db.parse(file);
  if (document == null) {
    throw new IOException("String_Node_Str" + file);
  }
  boolean modified=false;
  Node filesElem=getElement(document.getDocumentElement(),"String_Node_Str",1);
  Node fileSetsElem=getElement(document.getDocumentElement(),"String_Node_Str",1);
  if (fileSetsElem == null) {
    fileSetsElem=document.createElement("String_Node_Str");
    document.appendChild(fileSetsElem);
  }
  List<String> childrenPomsIncludes=new ArrayList<String>();
  List<String> childrenFolderResourcesIncludes=new ArrayList<String>();
  final Set<JobInfo> clonedChildrenJobInfors=getClonedJobInfos();
  for (  JobInfo child : clonedChildrenJobInfors) {
    modified=true;
    String jobClassPackageFolder=null;
    if (child.getProcessItem() != null) {
      jobClassPackageFolder=JavaResourcesHelper.getJobClassPackageFolder(child.getProcessItem());
    }
 else {
      String projectName=null;
      String jobId=child.getJobId();
      if (jobId != null) {
        IProxyRepositoryFactory proxyRepositoryFactory=CoreRuntimePlugin.getInstance().getProxyRepositoryFactory();
        IRepositoryViewObject lastVersion=proxyRepositoryFactory.getLastVersion(jobId);
        if (lastVersion != null) {
          Property property=lastVersion.getProperty();
          if (property != null) {
            Project project=ProjectManager.getInstance().getProject(property.getItem());
            projectName=project.getTechnicalLabel();
          }
        }
      }
      if (projectName == null) {
        projectName=ProjectManager.getInstance().getCurrentProject().getTechnicalLabel();
      }
      jobClassPackageFolder=JavaResourcesHelper.getJobClassPackageFolder(projectName,child.getJobName(),child.getJobVersion());
    }
    childrenPomsIncludes.add(PomUtil.getPomFileName(child.getJobName()));
    childrenFolderResourcesIncludes.add(jobClassPackageFolder + "String_Node_Str");
  }
  if (modified) {
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenPomsIncludes,null,null,null,null,false,"String_Node_Str");
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenFolderResourcesIncludes,null,null,null,null,false,"String_Node_Str");
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenFolderResourcesIncludes,null,null,null,null,false,"String_Node_Str");
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenFolderResourcesIncludes,null,null,null,null,false,"String_Node_Str");
  }
  if (modified) {
    TransformerFactory transFactory=TransformerFactory.newInstance();
    Transformer transFormer=transFactory.newTransformer();
    transFormer.setOutputProperty(OutputKeys.INDENT,"String_Node_Str");
    transFormer.transform(new DOMSource(document),new StreamResult(new FileOutputStream(file)));
  }
}

Fixed version (ground truth):
@SuppressWarnings("String_Node_Str") protected void addChildrenJobsInAssembly(IFile assemblyFile) throws Exception {
  if (!assemblyFile.exists()) {
    return;
  }
  final File file=assemblyFile.getLocation().toFile();
  DocumentBuilderFactory dbf=DocumentBuilderFactory.newInstance();
  DocumentBuilder db=dbf.newDocumentBuilder();
  Document document=db.parse(file);
  if (document == null) {
    throw new IOException("String_Node_Str" + file);
  }
  boolean modified=false;
  Node filesElem=getElement(document.getDocumentElement(),"String_Node_Str",1);
  Node fileSetsElem=getElement(document.getDocumentElement(),"String_Node_Str",1);
  if (fileSetsElem == null) {
    fileSetsElem=document.createElement("String_Node_Str");
    document.appendChild(fileSetsElem);
  }
  List<String> childrenPomsIncludes=new ArrayList<String>();
  List<String> childrenFolderResourcesIncludes=new ArrayList<String>();
  final Set<JobInfo> clonedChildrenJobInfors=getClonedJobInfos();
  for (  JobInfo child : clonedChildrenJobInfors) {
    modified=true;
    String jobClassPackageFolder=null;
    if (child.getProcessItem() != null) {
      jobClassPackageFolder=JavaResourcesHelper.getJobClassPackageFolder(child.getProcessItem());
    }
 else {
      String projectName=null;
      String jobId=child.getJobId();
      if (jobId != null) {
        IProxyRepositoryFactory proxyRepositoryFactory=CoreRuntimePlugin.getInstance().getProxyRepositoryFactory();
        IRepositoryViewObject lastVersion=proxyRepositoryFactory.getLastVersion(jobId);
        if (lastVersion != null) {
          Property property=lastVersion.getProperty();
          if (property != null) {
            Project project=ProjectManager.getInstance().getProject(property.getItem());
            projectName=project.getTechnicalLabel();
          }
        }
      }
      if (projectName == null) {
        projectName=ProjectManager.getInstance().getCurrentProject().getTechnicalLabel();
      }
      jobClassPackageFolder=JavaResourcesHelper.getJobClassPackageFolder(projectName,child.getJobName(),child.getJobVersion());
    }
    childrenPomsIncludes.add(PomUtil.getPomFileName(child.getJobName()));
    childrenFolderResourcesIncludes.add(jobClassPackageFolder + "String_Node_Str");
  }
  if (modified) {
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenPomsIncludes,null,null,null,null,false,"String_Node_Str");
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenFolderResourcesIncludes,null,null,null,null,false,"String_Node_Str");
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenFolderResourcesIncludes,null,null,null,null,false,"String_Node_Str");
    addAssemblyFileSets(fileSetsElem,"String_Node_Str","String_Node_Str",false,childrenFolderResourcesIncludes,null,null,null,null,false,"String_Node_Str");
  }
  if (modified) {
    TransformerFactory transFactory=TransformerFactory.newInstance();
    Transformer transFormer=transFactory.newTransformer();
    transFormer.setOutputProperty(OutputKeys.INDENT,"String_Node_Str");
    transFormer.transform(new DOMSource(document),new StreamResult(new FileOutputStream(file)));
    for (    String childPomFile : childrenPomsIncludes) {
      IFile childPom=assemblyFile.getProject().getFile(childPomFile);
      Model childModel=MODEL_MANAGER.readMavenModel(childPom);
      List<Plugin> childPlugins=new ArrayList<Plugin>(childModel.getBuild().getPlugins());
      Iterator<Plugin> childIterator=childPlugins.iterator();
      while (childIterator.hasNext()) {
        Plugin p=childIterator.next();
        if (p.getArtifactId().equals("String_Node_Str")) {
          childIterator.remove();
        }
      }
      childModel.getBuild().setPlugins(childPlugins);
      PomUtil.savePom(null,childModel,childPom);
    }
  }
}