Program: 123541
Project: 123541
Buggy source:
private void prepareEmfTreeNode(List<FOXTreeNode> list,TreeNode parent){
  if (list == null || list.isEmpty()) {
    return;
  }
  String xPath=parent.getXpath();
  for (  FOXTreeNode foxNode : list) {
    TreeNode createTreeNode=null;
    if (input) {
      createTreeNode=XmlmapFactory.eINSTANCE.createTreeNode();
    }
 else {
      createTreeNode=XmlmapFactory.eINSTANCE.createOutputTreeNode();
    }
    createTreeNode.setName(foxNode.getLabel());
    if (foxNode instanceof Element) {
      createTreeNode.setNodeType(NodeType.ELEMENT);
    }
 else     if (foxNode instanceof Attribute) {
      createTreeNode.setNodeType(NodeType.ATTRIBUT);
    }
 else     if (foxNode instanceof NameSpaceNode) {
      createTreeNode.setNodeType(NodeType.NAME_SPACE);
      createTreeNode.setDefaultValue(foxNode.getDefaultValue());
      if (createTreeNode.getName() == null || createTreeNode.getName().equals("String_Node_Str")) {
        createTreeNode.setName(XmlMapUtil.DEFAULT_NAME_SPACE_PREFIX);
      }
    }
    createTreeNode.setXpath(XmlMapUtil.getXPath(xPath,createTreeNode.getName(),createTreeNode.getNodeType()));
    if (foxNode.getDataType() != null && "String_Node_Str".equals(foxNode.getDataType())) {
      createTreeNode.setType(foxNode.getDataType());
    }
 else {
      createTreeNode.setType(XmlMapUtil.DEFAULT_DATA_TYPE);
    }
    parent.getChildren().add(createTreeNode);
    if (foxNode.getChildren() != null && !foxNode.getChildren().isEmpty()) {
      prepareEmfTreeNode(foxNode.getChildren(),createTreeNode);
    }
  }
}

Fixed version (ground truth):
private void prepareEmfTreeNode(List<FOXTreeNode> list,TreeNode parent){
  if (list == null || list.isEmpty()) {
    return;
  }
  String xPath=parent.getXpath();
  for (  FOXTreeNode foxNode : list) {
    TreeNode createTreeNode=null;
    if (input) {
      createTreeNode=XmlmapFactory.eINSTANCE.createTreeNode();
    }
 else {
      createTreeNode=XmlmapFactory.eINSTANCE.createOutputTreeNode();
    }
    createTreeNode.setName(foxNode.getLabel());
    if (foxNode instanceof Element) {
      createTreeNode.setNodeType(NodeType.ELEMENT);
    }
 else     if (foxNode instanceof Attribute) {
      createTreeNode.setNodeType(NodeType.ATTRIBUT);
    }
 else     if (foxNode instanceof NameSpaceNode) {
      createTreeNode.setNodeType(NodeType.NAME_SPACE);
      createTreeNode.setDefaultValue(foxNode.getDefaultValue());
      if (createTreeNode.getName() == null || createTreeNode.getName().equals("String_Node_Str")) {
        createTreeNode.setName(XmlMapUtil.DEFAULT_NAME_SPACE_PREFIX);
      }
    }
    createTreeNode.setXpath(XmlMapUtil.getXPath(xPath,createTreeNode.getName(),createTreeNode.getNodeType()));
    if (foxNode.getDataType() != null && !"String_Node_Str".equals(foxNode.getDataType())) {
      if (foxNode.getDataType().equals("String_Node_Str")) {
        createTreeNode.setPattern("String_Node_Str");
      }
      createTreeNode.setType(foxNode.getDataType());
    }
 else {
      createTreeNode.setType(XmlMapUtil.DEFAULT_DATA_TYPE);
    }
    parent.getChildren().add(createTreeNode);
    if (foxNode.getChildren() != null && !foxNode.getChildren().isEmpty()) {
      prepareEmfTreeNode(foxNode.getChildren(),createTreeNode);
    }
  }
}