Program: 40294
Project: 40294
Buggy source:
protected String createElement(HTML.Tag t,MutableAttributeSet a){
  String tag=t.toString().toUpperCase();
  if (tag.equals("String_Node_Str")) {
    Object l=a.getAttribute(HTML.Attribute.LANGUAGE);
    if (l == null || l.toString().toUpperCase().indexOf("String_Node_Str") < 0) {
      Object value=a.getAttribute(HTML.Attribute.SRC);
      if (value != null) {
        try {
          URL scriptSrc=new URL(input,value.toString());
          InputStreamReader scriptReader=new InputStreamReader(scriptSrc.openConnection().getInputStream());
          int read;
          char[] buffer=new char[1024];
          while ((read=scriptReader.read(buffer)) != -1) {
            writeEmbeddedScript(buffer,read);
          }
          embeddedScriptFile.flush();
          scriptReader.close();
        }
 catch (        IOException e) {
          System.out.println("String_Node_Str" + value);
        }
      }
 else {
        System.out.println("String_Node_Str");
        script=true;
      }
    }
  }
  String varName=null;
  Enumeration enu=a.getAttributeNames();
  while (enu.hasMoreElements()) {
    Object attrObj=enu.nextElement();
    String attr=attrObj.toString();
    String value=a.getAttribute(attrObj).toString();
    if (attr.equalsIgnoreCase("String_Node_Str")) {
      varName=value;
      break;
    }
  }
  if (varName == null) {
    varName="String_Node_Str" + (counter++);
  }
  String cons=constructors.get(tag);
  if (cons == null)   cons="String_Node_Str";
  try {
    writeElement(t,a,tag,cons,varName);
    domTreeFile.write("String_Node_Str");
  }
 catch (  IOException e) {
    System.out.println("String_Node_Str");
    System.exit(1);
  }
  return varName;
}

Fixed version (ground truth):
protected String createElement(HTML.Tag t,MutableAttributeSet a,int pos){
  String tag=t.toString().toUpperCase();
  if (tag.equals("String_Node_Str")) {
    Object l=a.getAttribute(HTML.Attribute.LANGUAGE);
    if (l == null || l.toString().toUpperCase().indexOf("String_Node_Str") < 0) {
      Object value=a.getAttribute(HTML.Attribute.SRC);
      if (value != null) {
        try {
          URL scriptSrc=new URL(input,value.toString());
          InputStreamReader scriptReader=new InputStreamReader(scriptSrc.openConnection().getInputStream());
          int read;
          char[] buffer=new char[1024];
          while ((read=scriptReader.read(buffer)) != -1) {
            writeEmbeddedScript(buffer,read);
          }
          embeddedScriptFile.flush();
          scriptReader.close();
        }
 catch (        IOException e) {
          System.out.println("String_Node_Str" + value);
        }
      }
 else {
        System.out.println("String_Node_Str");
        script=true;
        scriptStart=pos;
      }
    }
  }
  String varName=null;
  Enumeration enu=a.getAttributeNames();
  while (enu.hasMoreElements()) {
    Object attrObj=enu.nextElement();
    String attr=attrObj.toString();
    String value=a.getAttribute(attrObj).toString();
    if (attr.equalsIgnoreCase("String_Node_Str")) {
      varName=value;
      break;
    }
  }
  if (varName == null) {
    varName="String_Node_Str" + (counter++);
  }
  String cons=constructors.get(tag);
  if (cons == null)   cons="String_Node_Str";
  try {
    writeElement(t,a,tag,cons,varName);
    domTreeFile.write("String_Node_Str");
  }
 catch (  IOException e) {
    System.out.println("String_Node_Str");
    System.exit(1);
  }
  return varName;
}