Program: 20564
Project: 20564
Buggy source:
protected IType resolveType(IType ownerType,String typeName) throws JavaModelException {
  if (typeName.startsWith("String_Node_Str") && typeName.endsWith("String_Node_Str")) {
    return null;
  }
  if (!typeName.endsWith("String_Node_Str")) {
    int ind=typeName.indexOf("String_Node_Str");
    if (ind >= 0) {
      typeName="String_Node_Str" + typeName.substring(0,ind);
    }
    IType type=ownerType.getJavaProject().findType(typeName);
    if (type == null) {
      String[][] resolveType=ownerType.resolveType(typeName);
      if (resolveType == null) {
        throw new GenerationException("String_Node_Str" + typeName + "String_Node_Str","String_Node_Str" + typeName + "String_Node_Str");
      }
      if (resolveType.length == 1) {
        type=ownerType.getJavaProject().findType(resolveType[0][0] + '.' + resolveType[0][1]);
      }
    }
    return type;
  }
  if (typeName.startsWith("String_Node_Str") && typeName.endsWith("String_Node_Str")) {
    typeName=Signature.getTypeErasure(typeName);
    typeName=typeName.substring(1,typeName.length() - 1);
    IType type=ownerType.getJavaProject().findType(typeName);
    return type;
  }
  String tn;
  if (typeName.startsWith("String_Node_Str") && typeName.endsWith("String_Node_Str")) {
    tn=Signature.getTypeErasure(typeName);
  }
 else {
    tn=typeName;
  }
  tn=tn.substring(1,tn.length() - 1);
  String[][] resolveType=ownerType.resolveType(tn);
  if (resolveType == null) {
    throw new GenerationException("String_Node_Str" + typeName + "String_Node_Str","String_Node_Str" + typeName + "String_Node_Str");
  }
  IType findType=null;
  if (resolveType.length == 1) {
    findType=ownerType.getJavaProject().findType(resolveType[0][0] + '.' + resolveType[0][1]);
  }
  return findType;
}

Fixed version (ground truth):
protected IType resolveType(IType ownerType,String typeName) throws JavaModelException {
  if (typeName.startsWith("String_Node_Str") && typeName.endsWith("String_Node_Str")) {
    return null;
  }
  if (!typeName.endsWith("String_Node_Str")) {
    typeName=Signature.getTypeErasure(typeName);
    IType type=ownerType.getJavaProject().findType(typeName);
    if (type == null) {
      String[][] resolveType=ownerType.resolveType(typeName);
      if (resolveType == null) {
        throw new GenerationException("String_Node_Str" + typeName + "String_Node_Str","String_Node_Str" + typeName + "String_Node_Str");
      }
      if (resolveType.length == 1) {
        type=ownerType.getJavaProject().findType(resolveType[0][0] + '.' + resolveType[0][1]);
      }
    }
    return type;
  }
  if (typeName.startsWith("String_Node_Str") && typeName.endsWith("String_Node_Str")) {
    typeName=Signature.getTypeErasure(typeName);
    typeName=typeName.substring(1,typeName.length() - 1);
    IType type=ownerType.getJavaProject().findType(typeName);
    return type;
  }
  String tn;
  if (typeName.startsWith("String_Node_Str") && typeName.endsWith("String_Node_Str")) {
    tn=Signature.getTypeErasure(typeName);
  }
 else {
    tn=typeName;
  }
  tn=tn.substring(1,tn.length() - 1);
  String[][] resolveType=ownerType.resolveType(tn);
  if (resolveType == null) {
    throw new GenerationException("String_Node_Str" + typeName + "String_Node_Str","String_Node_Str" + typeName + "String_Node_Str");
  }
  IType findType=null;
  if (resolveType.length == 1) {
    findType=ownerType.getJavaProject().findType(resolveType[0][0] + '.' + resolveType[0][1]);
  }
  return findType;
}