Program: 9742
Project: 9742
Buggy source:
/** 
 * The new method always static. It may take some extra arguments:  this, target. If it's argsOnStack, then it must take both this/target If it's argsOnFrame, it shares this and target. ??? rewrite this to do less array munging, please
 */
private LazyMethodGen createMethodGen(String newMethodName){
  Type[] parameterTypes=world.makeBcelTypes(getSignature().getParameterTypes());
  int modifiers=Modifier.FINAL;
  modifiers|=Modifier.STATIC;
  if (targetVar != null && targetVar != thisVar) {
    TypeX targetType=getTargetType();
    ResolvedMember resolvedMember=getSignature().resolve(world);
    if (resolvedMember != null && Modifier.isProtected(resolvedMember.getModifiers()) && !samePackage(targetType.getPackageName(),getThisType().getPackageName())) {
      if (!targetType.isAssignableFrom(getThisType(),world)) {
        throw new BCException("String_Node_Str");
      }
      targetType=getThisType();
    }
    parameterTypes=addType(world.makeBcelType(targetType),parameterTypes);
  }
  if (thisVar != null) {
    TypeX thisType=getThisType();
    parameterTypes=addType(world.makeBcelType(thisType),parameterTypes);
  }
  if (thisJoinPointVar != null) {
    parameterTypes=addTypeToEnd(LazyClassGen.tjpType,parameterTypes);
  }
  TypeX returnType;
  if (getKind() == ConstructorCall) {
    returnType=getSignature().getDeclaringType();
  }
 else   if (getKind() == PreInitialization) {
    returnType=TypeX.OBJECTARRAY;
  }
 else {
    returnType=getSignature().getReturnType();
  }
  return new LazyMethodGen(modifiers,world.makeBcelType(returnType),newMethodName,parameterTypes,new String[0],getEnclosingClass());
}

Fixed version (ground truth):
/** 
 * The new method always static. It may take some extra arguments:  this, target. If it's argsOnStack, then it must take both this/target If it's argsOnFrame, it shares this and target. ??? rewrite this to do less array munging, please
 */
private LazyMethodGen createMethodGen(String newMethodName){
  Type[] parameterTypes=world.makeBcelTypes(getArgTypes());
  int modifiers=Modifier.FINAL;
  modifiers|=Modifier.STATIC;
  if (targetVar != null && targetVar != thisVar) {
    TypeX targetType=getTargetType();
    ResolvedMember resolvedMember=getSignature().resolve(world);
    if (resolvedMember != null && Modifier.isProtected(resolvedMember.getModifiers()) && !samePackage(targetType.getPackageName(),getThisType().getPackageName())) {
      if (!targetType.isAssignableFrom(getThisType(),world)) {
        throw new BCException("String_Node_Str");
      }
      targetType=getThisType();
    }
    parameterTypes=addType(world.makeBcelType(targetType),parameterTypes);
  }
  if (thisVar != null) {
    TypeX thisType=getThisType();
    parameterTypes=addType(world.makeBcelType(thisType),parameterTypes);
  }
  if (thisJoinPointVar != null) {
    parameterTypes=addTypeToEnd(LazyClassGen.tjpType,parameterTypes);
  }
  TypeX returnType;
  if (getKind() == ConstructorCall) {
    returnType=getSignature().getDeclaringType();
  }
 else   if (getKind() == PreInitialization) {
    returnType=TypeX.OBJECTARRAY;
  }
 else {
    returnType=getSignature().getReturnType();
  }
  return new LazyMethodGen(modifiers,world.makeBcelType(returnType),newMethodName,parameterTypes,new String[0],getEnclosingClass());
}