Program: 37005
Project: 37005
Buggy source:
void handleTasks(ReportContext report,XsdAttributeRoot buildUnit){
  XsdTasks tasks=report.getTasks();
  Map<String,RulePriority> priorityMap=new HashMap<String,RulePriority>();
  Rule rule=ruleFinder.findByKey(SonargraphPluginBase.PLUGIN_KEY,SonargraphPluginBase.TASK_RULE_KEY);
  int count=0;
  if (rule == null) {
    LOG.error("String_Node_Str");
    return;
  }
  priorityMap.put("String_Node_Str",RulePriority.INFO);
  priorityMap.put("String_Node_Str",RulePriority.MINOR);
  priorityMap.put("String_Node_Str",RulePriority.MAJOR);
  for (  XsdTask task : tasks.getTask()) {
    String bu=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
    bu=Utilities.getBuildUnitName(bu);
    if (bu.equals(Utilities.getBuildUnitName(buildUnit.getName()))) {
      String priority=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
      String description=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
      String assignedTo=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
      description=handleDescription(description);
      int index=description.indexOf("String_Node_Str");
      if (index > 0 && index < 8) {
        count++;
      }
 else {
        if (assignedTo != null) {
          assignedTo='[' + assignedTo.trim() + ']';
          if (assignedTo.length() > 2) {
            description+=' ' + assignedTo;
          }
        }
        for (        XsdPosition pos : task.getPosition()) {
          String relFileName=pos.getFile();
          if (relFileName != null) {
            String fqName=Utilities.relativeFileNameToFqName(relFileName);
            int line=Integer.valueOf(pos.getLine());
            if (line == 0) {
              line=1;
            }
            saveViolation(rule,priorityMap.get(priority),fqName,line,description);
          }
          count++;
        }
      }
    }
  }
  saveMeasureToContext(SonargraphBuildUnitMetrics.TASK_REFS,count,0);
}

Fixed version (ground truth):
void handleTasks(ReportContext report,XsdAttributeRoot buildUnit){
  LOG.debug("String_Node_Str" + buildUnit.getName());
  XsdTasks tasks=report.getTasks();
  Map<String,RulePriority> priorityMap=new HashMap<String,RulePriority>();
  Rule rule=ruleFinder.findByKey(SonargraphPluginBase.PLUGIN_KEY,SonargraphPluginBase.TASK_RULE_KEY);
  int count=0;
  if (rule == null) {
    LOG.error("String_Node_Str");
    return;
  }
  priorityMap.put("String_Node_Str",RulePriority.INFO);
  priorityMap.put("String_Node_Str",RulePriority.MINOR);
  priorityMap.put("String_Node_Str",RulePriority.MAJOR);
  for (  XsdTask task : tasks.getTask()) {
    String bu=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
    bu=Utilities.getBuildUnitName(bu);
    if (bu.equals(Utilities.getBuildUnitName(buildUnit.getName()))) {
      String priority=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
      String description=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
      String assignedTo=Utilities.getAttribute(task.getAttribute(),"String_Node_Str");
      description=handleDescription(description);
      int index=description.indexOf("String_Node_Str");
      if (index > 0 && index < 8) {
        count++;
      }
 else {
        if (assignedTo != null) {
          assignedTo='[' + assignedTo.trim() + ']';
          if (assignedTo.length() > 2) {
            description+=' ' + assignedTo;
          }
        }
        for (        XsdPosition pos : task.getPosition()) {
          String relFileName=pos.getFile();
          if (relFileName != null) {
            String fqName=Utilities.relativeFileNameToFqName(relFileName);
            int line=Integer.valueOf(pos.getLine());
            if (line == 0) {
              line=1;
            }
            saveViolation(rule,priorityMap.get(priority),fqName,line,description);
          }
          count++;
        }
      }
    }
  }
  saveMeasureToContext(SonargraphBuildUnitMetrics.TASK_REFS,count,0);
}