Program: 49785
Project: 49785
Buggy source:
protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.versions);
  bible=Bible.getBible(this);
  String[] from={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  int[] to={R.id.code,R.id.name,R.id.action,0};
  adapter=new SimpleAdapter(this,data,R.layout.version,from,to){
    @Override public View getView(    int position,    View convertView,    ViewGroup parent){
      View view=super.getView(position,convertView,parent);
      final TextView action=(TextView)view.findViewById(R.id.action);
      if (action != null) {
        action.setTag(position);
        action.setOnClickListener(new View.OnClickListener(){
          @Override public void onClick(          View view){
            int position=(Integer)view.getTag();
            @SuppressWarnings("String_Node_Str") Map<String,String> map=(Map<String,String>)getItem(position);
            clickVersion((TextView)view,map);
          }
        }
);
      }
      return view;
    }
    Filter mFilter;
    public Filter getFilter(){
      if (mFilter == null) {
        mFilter=new SimpleFilter();
      }
      return mFilter;
    }
class SimpleFilter extends Filter {
      @Override protected FilterResults performFiltering(      CharSequence prefix){
        FilterResults results=new FilterResults();
        String filter=null;
        if (prefix != null && prefix.length() > 0) {
          filter=prefix.toString().toLowerCase(Locale.US);
        }
        data.clear();
        for (        Map<String,String> map : versions) {
          if (filter == null) {
            data.add(map);
          }
 else {
            for (            String value : map.values()) {
              if (value.toLowerCase(Locale.US).contains(filter)) {
                data.add(map);
                break;
              }
            }
          }
        }
        results.count=data.size();
        return results;
      }
      @Override protected void publishResults(      CharSequence constraint,      FilterResults results){
        if (results.count > 0) {
          notifyDataSetChanged();
        }
 else {
          notifyDataSetInvalidated();
        }
      }
    }
  }
;
  final ListView list=(ListView)findViewById(android.R.id.list);
  list.setAdapter(adapter);
  list.setOnItemClickListener(new AdapterView.OnItemClickListener(){
    @Override public void onItemClick(    AdapterView<?> parent,    View view,    int position,    long id){
      @SuppressWarnings("String_Node_Str") Map<String,String> map=(Map<String,String>)list.getItemAtPosition(position);
      TextView action=(TextView)view.findViewById(R.id.action);
      clickVersion(action,map);
    }
  }
);
  final EditText editText=(EditText)findViewById(R.id.query);
  editText.addTextChangedListener(new TextWatcher(){
    @Override public void beforeTextChanged(    CharSequence s,    int start,    int before,    int after){
    }
    @Override public void onTextChanged(    CharSequence s,    int start,    int before,    int after){
      filter=s;
      adapter.getFilter().filter(s);
    }
    @Override public void afterTextChanged(    Editable s){
    }
  }
);
  refresh=(ImageView)findViewById(R.id.refresh);
  refresh.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      refreshVersions();
    }
  }
);
}

Fixed version (ground truth):
protected void onCreate(Bundle savedInstanceState){
  super.onCreate(savedInstanceState);
  setContentView(R.layout.versions);
  bible=Bible.getBible(this);
  String[] from={"String_Node_Str","String_Node_Str","String_Node_Str","String_Node_Str"};
  int[] to={R.id.code,R.id.name,R.id.action,0};
  adapter=new SimpleAdapter(this,data,R.layout.version,from,to){
    @Override public View getView(    int position,    View convertView,    ViewGroup parent){
      if (data.size() <= position) {
synchronized (data) {
          data.clear();
          for (          Map<String,String> map : versions) {
            data.add(map);
          }
        }
      }
      View view=super.getView(position,convertView,parent);
      final TextView action=(TextView)view.findViewById(R.id.action);
      if (action != null) {
        action.setTag(position);
        action.setOnClickListener(new View.OnClickListener(){
          @Override public void onClick(          View view){
            int position=(Integer)view.getTag();
            @SuppressWarnings("String_Node_Str") Map<String,String> map=(Map<String,String>)getItem(position);
            clickVersion((TextView)view,map);
          }
        }
);
      }
      return view;
    }
    Filter mFilter;
    public Filter getFilter(){
      if (mFilter == null) {
        mFilter=new SimpleFilter();
      }
      return mFilter;
    }
class SimpleFilter extends Filter {
      @Override protected FilterResults performFiltering(      CharSequence prefix){
        FilterResults results=new FilterResults();
        String filter=null;
        if (prefix != null && prefix.length() > 0) {
          filter=prefix.toString().toLowerCase(Locale.US);
        }
synchronized (data) {
          data.clear();
          for (          Map<String,String> map : versions) {
            if (filter == null) {
              data.add(map);
            }
 else {
              for (              String value : map.values()) {
                if (value.toLowerCase(Locale.US).contains(filter)) {
                  data.add(map);
                  break;
                }
              }
            }
          }
        }
        results.count=data.size();
        return results;
      }
      @Override protected void publishResults(      CharSequence constraint,      FilterResults results){
        if (results.count > 0) {
          notifyDataSetChanged();
        }
 else {
          notifyDataSetInvalidated();
        }
      }
    }
  }
;
  final ListView list=(ListView)findViewById(android.R.id.list);
  list.setAdapter(adapter);
  list.setOnItemClickListener(new AdapterView.OnItemClickListener(){
    @Override public void onItemClick(    AdapterView<?> parent,    View view,    int position,    long id){
      @SuppressWarnings("String_Node_Str") Map<String,String> map=(Map<String,String>)list.getItemAtPosition(position);
      TextView action=(TextView)view.findViewById(R.id.action);
      clickVersion(action,map);
    }
  }
);
  query=(EditText)findViewById(R.id.query);
  query.addTextChangedListener(new TextWatcher(){
    @Override public void beforeTextChanged(    CharSequence s,    int start,    int before,    int after){
    }
    @Override public void onTextChanged(    CharSequence s,    int start,    int before,    int after){
      adapter.getFilter().filter(s);
    }
    @Override public void afterTextChanged(    Editable s){
    }
  }
);
  refresh=(ImageView)findViewById(R.id.refresh);
  refresh.setOnClickListener(new View.OnClickListener(){
    @Override public void onClick(    View v){
      refreshVersions();
    }
  }
);
}