Program: 3115
Project: 3115
Buggy source:
public MethodVisitor visitMethod(final int access,final String name,final String desc,String signature,String[] exceptions){
  MethodVisitor methodVisitor=super.visitMethod(access,name,desc,signature,exceptions);
  if (emptyMethods.contains(MethodID.create(name,desc)))   return methodVisitor;
  if (applicableOnMethods.size() == 0 || (access & ACC_ABSTRACT) != 0 || (access & ACC_NATIVE) != 0 || name.startsWith(BTRACE_METHOD_PREFIX)) {
    return methodVisitor;
  }
  for (  OnMethod om : applicableOnMethods) {
    if (om.getLocation().getValue() == Kind.LINE) {
      methodVisitor=instrumentorFor(om,methodVisitor,access,name,desc);
    }
 else {
      String methodName=om.getMethod();
      if (methodName.equals("String_Node_Str")) {
        methodName=om.getTargetName();
      }
      if (methodName.equals(name) && typeMatches(om.getType(),desc)) {
        methodVisitor=instrumentorFor(om,methodVisitor,access,name,desc);
      }
 else       if (methodName.charAt(0) == '/' && REGEX_SPECIFIER.matcher(methodName).matches()) {
        methodName=methodName.substring(1,methodName.length() - 1);
        if (name.matches(methodName) && typeMatches(om.getType(),desc)) {
          methodVisitor=instrumentorFor(om,methodVisitor,access,name,desc);
        }
      }
    }
  }
  return new MethodAdapter(methodVisitor){
    public AnnotationVisitor visitAnnotation(    String annoDesc,    boolean visible){
      for (      OnMethod om : applicableOnMethods) {
        String extAnnoName=Type.getType(annoDesc).getClassName();
        String annoName=om.getMethod();
        if (annoName.length() > 0 && annoName.charAt(0) == '@') {
          annoName=annoName.substring(1);
          if (annoName.length() == 0) {
            continue;
          }
          if (REGEX_SPECIFIER.matcher(annoName).matches()) {
            annoName=annoName.substring(1,annoName.length() - 1);
            if (extAnnoName.matches(annoName)) {
              mv=instrumentorFor(om,mv,access,name,desc);
            }
          }
 else           if (annoName.equals(extAnnoName)) {
            mv=instrumentorFor(om,mv,access,name,desc);
          }
        }
      }
      return mv.visitAnnotation(annoDesc,visible);
    }
  }
;
}

Fixed version (ground truth):
public MethodVisitor visitMethod(final int access,final String name,final String desc,String signature,String[] exceptions){
  MethodVisitor methodVisitor=super.visitMethod(access,name,desc,signature,exceptions);
  if (applicableOnMethods.size() == 0 || (access & ACC_ABSTRACT) != 0 || (access & ACC_NATIVE) != 0 || name.startsWith(BTRACE_METHOD_PREFIX)) {
    return methodVisitor;
  }
  for (  OnMethod om : applicableOnMethods) {
    if (om.getLocation().getValue() == Kind.LINE) {
      methodVisitor=instrumentorFor(om,methodVisitor,access,name,desc);
    }
 else {
      String methodName=om.getMethod();
      if (methodName.equals("String_Node_Str")) {
        methodName=om.getTargetName();
      }
      if (methodName.equals(name) && typeMatches(om.getType(),desc)) {
        methodVisitor=instrumentorFor(om,methodVisitor,access,name,desc);
      }
 else       if (methodName.charAt(0) == '/' && REGEX_SPECIFIER.matcher(methodName).matches()) {
        methodName=methodName.substring(1,methodName.length() - 1);
        if (name.matches(methodName) && typeMatches(om.getType(),desc)) {
          methodVisitor=instrumentorFor(om,methodVisitor,access,name,desc);
        }
      }
    }
  }
  return new MethodAdapter(methodVisitor){
    public AnnotationVisitor visitAnnotation(    String annoDesc,    boolean visible){
      for (      OnMethod om : applicableOnMethods) {
        String extAnnoName=Type.getType(annoDesc).getClassName();
        String annoName=om.getMethod();
        if (annoName.length() > 0 && annoName.charAt(0) == '@') {
          annoName=annoName.substring(1);
          if (annoName.length() == 0) {
            continue;
          }
          if (REGEX_SPECIFIER.matcher(annoName).matches()) {
            annoName=annoName.substring(1,annoName.length() - 1);
            if (extAnnoName.matches(annoName)) {
              mv=instrumentorFor(om,mv,access,name,desc);
            }
          }
 else           if (annoName.equals(extAnnoName)) {
            mv=instrumentorFor(om,mv,access,name,desc);
          }
        }
      }
      return mv.visitAnnotation(annoDesc,visible);
    }
  }
;
}