Program: 9294
Project: 9294
Buggy source:
public void initializeKindedAnnotationVars(){
  if (kindedAnnotationVars != null)   return;
  kindedAnnotationVars=new HashMap();
  ResolvedType[] annotations=null;
  Member relevantMember=getSignature();
  ResolvedType relevantType=relevantMember.getDeclaringType().resolve(world);
  if (getKind() == Shadow.StaticInitialization) {
    annotations=relevantType.resolve(world).getAnnotationTypes();
  }
 else   if (getKind() == Shadow.MethodCall || getKind() == Shadow.ConstructorCall) {
    relevantMember=findMethod2(relevantType.resolve(world).getDeclaredMethods(),getSignature());
    annotations=getAnnotations(relevantMember,relevantType);
    relevantMember=getRelevantMember(relevantMember,relevantType);
  }
 else   if (getKind() == Shadow.FieldSet || getKind() == Shadow.FieldGet) {
    relevantMember=findField(relevantType.getDeclaredFields(),getSignature());
    if (relevantMember == null) {
      List mungers=relevantType.resolve(world).getInterTypeMungers();
      for (Iterator iter=mungers.iterator(); iter.hasNext(); ) {
        BcelTypeMunger typeMunger=(BcelTypeMunger)iter.next();
        if (typeMunger.getMunger() instanceof NewFieldTypeMunger) {
          ResolvedMember fakerm=typeMunger.getSignature();
          ResolvedMember ajcMethod=AjcMemberMaker.interFieldInitializer(fakerm,typeMunger.getAspectType());
          ResolvedMember rmm=findMethod(typeMunger.getAspectType(),ajcMethod);
          if (fakerm.equals(getSignature())) {
            relevantType=typeMunger.getAspectType();
            relevantMember=rmm;
          }
        }
      }
    }
    annotations=relevantMember.getAnnotationTypes();
  }
 else   if (getKind() == Shadow.MethodExecution || getKind() == Shadow.ConstructorExecution || getKind() == Shadow.AdviceExecution) {
    ResolvedMember rm[]=relevantType.getDeclaredMethods();
    relevantMember=findMethod2(relevantType.getDeclaredMethods(),getSignature());
    annotations=getAnnotations(relevantMember,relevantType);
    relevantMember=getRelevantMember(relevantMember,relevantType);
  }
 else   if (getKind() == Shadow.ExceptionHandler) {
    relevantType=getSignature().getParameterTypes()[0].resolve(world);
    annotations=relevantType.getAnnotationTypes();
  }
 else   if (getKind() == Shadow.PreInitialization || getKind() == Shadow.Initialization) {
    ResolvedMember found=findMethod2(relevantType.getDeclaredMethods(),getSignature());
    annotations=found.getAnnotationTypes();
  }
  if (annotations == null) {
    throw new BCException("String_Node_Str" + getKind());
  }
  for (int i=0; i < annotations.length; i++) {
    ResolvedType aTX=annotations[i];
    KindedAnnotationAccessVar kaav=new KindedAnnotationAccessVar(getKind(),aTX.resolve(world),relevantType,relevantMember);
    kindedAnnotationVars.put(aTX,kaav);
  }
}

Fixed version (ground truth):
public void initializeKindedAnnotationVars(){
  if (kindedAnnotationVars != null)   return;
  kindedAnnotationVars=new HashMap();
  ResolvedType[] annotations=null;
  Member relevantMember=getSignature();
  ResolvedType relevantType=relevantMember.getDeclaringType().resolve(world);
  if (getKind() == Shadow.StaticInitialization) {
    annotations=relevantType.resolve(world).getAnnotationTypes();
  }
 else   if (getKind() == Shadow.MethodCall || getKind() == Shadow.ConstructorCall) {
    Member foundMember=findMethod2(relevantType.resolve(world).getDeclaredMethods(),getSignature());
    annotations=getAnnotations(foundMember,relevantMember,relevantType);
    relevantMember=getRelevantMember(foundMember,relevantMember,relevantType);
    relevantType=relevantMember.getDeclaringType().resolve(world);
  }
 else   if (getKind() == Shadow.FieldSet || getKind() == Shadow.FieldGet) {
    relevantMember=findField(relevantType.getDeclaredFields(),getSignature());
    if (relevantMember == null) {
      List mungers=relevantType.resolve(world).getInterTypeMungers();
      for (Iterator iter=mungers.iterator(); iter.hasNext(); ) {
        BcelTypeMunger typeMunger=(BcelTypeMunger)iter.next();
        if (typeMunger.getMunger() instanceof NewFieldTypeMunger) {
          ResolvedMember fakerm=typeMunger.getSignature();
          ResolvedMember ajcMethod=AjcMemberMaker.interFieldInitializer(fakerm,typeMunger.getAspectType());
          ResolvedMember rmm=findMethod(typeMunger.getAspectType(),ajcMethod);
          if (fakerm.equals(getSignature())) {
            relevantType=typeMunger.getAspectType();
            relevantMember=rmm;
          }
        }
      }
    }
    annotations=relevantMember.getAnnotationTypes();
  }
 else   if (getKind() == Shadow.MethodExecution || getKind() == Shadow.ConstructorExecution || getKind() == Shadow.AdviceExecution) {
    ResolvedMember rm[]=relevantType.getDeclaredMethods();
    Member foundMember=findMethod2(relevantType.getDeclaredMethods(),getSignature());
    annotations=getAnnotations(foundMember,relevantMember,relevantType);
    relevantMember=foundMember;
    relevantMember=getRelevantMember(foundMember,relevantMember,relevantType);
  }
 else   if (getKind() == Shadow.ExceptionHandler) {
    relevantType=getSignature().getParameterTypes()[0].resolve(world);
    annotations=relevantType.getAnnotationTypes();
  }
 else   if (getKind() == Shadow.PreInitialization || getKind() == Shadow.Initialization) {
    ResolvedMember found=findMethod2(relevantType.getDeclaredMethods(),getSignature());
    annotations=found.getAnnotationTypes();
  }
  if (annotations == null) {
    throw new BCException("String_Node_Str" + getKind());
  }
  for (int i=0; i < annotations.length; i++) {
    ResolvedType aTX=annotations[i];
    KindedAnnotationAccessVar kaav=new KindedAnnotationAccessVar(getKind(),aTX.resolve(world),relevantType,relevantMember);
    kindedAnnotationVars.put(aTX,kaav);
  }
}