Program: 122491
Project: 122491
Buggy source:
private List<String> getComponentsFamilyFromXML(File xmlMainFile){
  final DocumentBuilderFactory fabrique=DocumentBuilderFactory.newInstance();
  final String familysTag="String_Node_Str";
  final String header="String_Node_Str";
  final String technical="String_Node_Str";
  List<String> familyNames=new ArrayList<String>();
  DocumentBuilder analyseur;
  try {
    analyseur=fabrique.newDocumentBuilder();
    analyseur.setErrorHandler(new ErrorHandler(){
      public void error(      final SAXParseException exception) throws SAXException {
        throw exception;
      }
      public void fatalError(      final SAXParseException exception) throws SAXException {
        throw exception;
      }
      public void warning(      final SAXParseException exception) throws SAXException {
        throw exception;
      }
    }
);
    Document document=analyseur.parse(xmlMainFile);
    NodeList elementsByTagName=document.getElementsByTagName(header);
    String technicalValue=null;
    if (elementsByTagName != null && elementsByTagName.getLength() > 0) {
      Node item=elementsByTagName.item(0);
      NamedNodeMap attributes=item.getAttributes();
      if (attributes != null) {
        Node namedItem=attributes.getNamedItem(technical);
        if (namedItem != null) {
          technicalValue=namedItem.getNodeValue();
        }
      }
    }
    if (technicalValue == null || !"String_Node_Str".equals(technicalValue)) {
      NodeList element=document.getElementsByTagName(familysTag);
      if (element != null && element.getLength() > 0) {
        Node family=element.item(0);
        NodeList childNodes=family.getChildNodes();
        for (int i=0; i < childNodes.getLength(); i++) {
          final Node item=childNodes.item(i);
          if (item instanceof com.sun.org.apache.xerces.internal.dom.DeferredElementImpl || item instanceof org.apache.xerces.dom.DeferredElementImpl) {
            familyNames.add(item.getTextContent());
          }
        }
      }
    }
  }
 catch (  ParserConfigurationException e) {
    ExceptionHandler.process(e);
  }
catch (  SAXException e) {
    ExceptionHandler.process(e);
  }
catch (  IOException e) {
    ExceptionHandler.process(e);
  }
  return familyNames;
}

Fixed version (ground truth):
private List<String> getComponentsFamilyFromXML(File xmlMainFile){
  final DocumentBuilderFactory fabrique=DocumentBuilderFactory.newInstance();
  final String familysTag="String_Node_Str";
  final String header="String_Node_Str";
  final String technical="String_Node_Str";
  List<String> familyNames=new ArrayList<String>();
  DocumentBuilder analyseur;
  try {
    analyseur=fabrique.newDocumentBuilder();
    analyseur.setErrorHandler(new ErrorHandler(){
      @Override public void error(      final SAXParseException exception) throws SAXException {
        throw exception;
      }
      @Override public void fatalError(      final SAXParseException exception) throws SAXException {
        throw exception;
      }
      @Override public void warning(      final SAXParseException exception) throws SAXException {
        throw exception;
      }
    }
);
    Document document=analyseur.parse(xmlMainFile);
    NodeList elementsByTagName=document.getElementsByTagName(header);
    String technicalValue=null;
    if (elementsByTagName != null && elementsByTagName.getLength() > 0) {
      Node item=elementsByTagName.item(0);
      NamedNodeMap attributes=item.getAttributes();
      if (attributes != null) {
        Node namedItem=attributes.getNamedItem(technical);
        if (namedItem != null) {
          technicalValue=namedItem.getNodeValue();
        }
      }
    }
    if (technicalValue == null || !"String_Node_Str".equals(technicalValue)) {
      NodeList element=document.getElementsByTagName(familysTag);
      if (element != null && element.getLength() > 0) {
        Node family=element.item(0);
        NodeList childNodes=family.getChildNodes();
        for (int i=0; i < childNodes.getLength(); i++) {
          final Node item=childNodes.item(i);
          if (item instanceof com.sun.org.apache.xerces.internal.dom.DeferredElementImpl || item instanceof org.apache.xerces.dom.DeferredElementImpl) {
            familyNames.add(item.getTextContent());
          }
        }
      }
    }
  }
 catch (  ParserConfigurationException e) {
    ExceptionHandler.process(e);
  }
catch (  SAXException e) {
    ExceptionHandler.process(e);
  }
catch (  IOException e) {
    ExceptionHandler.process(e);
  }
  return familyNames;
}