Program: 165461
Project: 165461
Buggy source:
@Override public SearchResult[] getSearchResults(String searchString) throws IOException {
  System.out.println("String_Node_Str" + searchString);
  scrapedPosters=null;
  if (useSiteSearch) {
    ArrayList<SearchResult> linksList=new ArrayList<SearchResult>();
    Document doc=Jsoup.connect(searchString).userAgent("String_Node_Str").ignoreHttpErrors(true).timeout(SiteParsingProfile.CONNECTION_TIMEOUT_VALUE).get();
    Elements movieSearchResultElements=doc.select("String_Node_Str");
    if (movieSearchResultElements == null || movieSearchResultElements.size() == 0) {
      this.useSiteSearch=false;
      SearchResult[] googleResults=getData18LinksFromGoogle(fileName);
      return googleResults;
    }
 else {
      for (      Element currentMovie : movieSearchResultElements) {
        String currentMovieURL=currentMovie.select("String_Node_Str").first().attr("String_Node_Str");
        String currentMovieTitle=currentMovie.select("String_Node_Str").last().text();
        String releaseDateText=currentMovie.ownText();
        if (releaseDateText != null && releaseDateText.length() > 0)         currentMovieTitle=currentMovieTitle + "String_Node_Str" + releaseDateText+ "String_Node_Str";
        Thumb currentMovieThumb=new Thumb(currentMovie.select("String_Node_Str").attr("String_Node_Str"));
        linksList.add(new SearchResult(currentMovieURL,currentMovieTitle,currentMovieThumb));
      }
      return linksList.toArray(new SearchResult[linksList.size()]);
    }
  }
 else {
    this.useSiteSearch=false;
    SearchResult[] googleResults=getData18LinksFromGoogle(fileName);
    return googleResults;
  }
}

Fixed version (ground truth):
@Override public SearchResult[] getSearchResults(String searchString) throws IOException {
  System.out.println("String_Node_Str" + searchString);
  scrapedPosters=null;
  if (useSiteSearch) {
    ArrayList<SearchResult> linksList=new ArrayList<SearchResult>();
    Document doc=Jsoup.connect(searchString).userAgent("String_Node_Str").ignoreHttpErrors(true).timeout(SiteParsingProfile.CONNECTION_TIMEOUT_VALUE).get();
    Elements movieSearchResultElements=doc.select("String_Node_Str");
    if (movieSearchResultElements == null || movieSearchResultElements.size() == 0) {
      this.useSiteSearch=false;
      SearchResult[] googleResults=getData18LinksFromGoogle(fileName);
      return googleResults;
    }
 else {
      for (      Element currentMovie : movieSearchResultElements) {
        String currentMovieURL=currentMovie.select("String_Node_Str").first().attr("String_Node_Str");
        String currentMovieTitle=currentMovie.select("String_Node_Str").first().text();
        String releaseDateText=currentMovie.ownText();
        if (releaseDateText != null && releaseDateText.length() > 0)         currentMovieTitle=currentMovieTitle + "String_Node_Str" + releaseDateText+ "String_Node_Str";
        Thumb currentMovieThumb=new Thumb(currentMovie.select("String_Node_Str").attr("String_Node_Str"));
        linksList.add(new SearchResult(currentMovieURL,currentMovieTitle,currentMovieThumb));
      }
      return linksList.toArray(new SearchResult[linksList.size()]);
    }
  }
 else {
    this.useSiteSearch=false;
    SearchResult[] googleResults=getData18LinksFromGoogle(fileName);
    return googleResults;
  }
}