Program: 104929
Project: 104929
Buggy source:
void onPageLoadComplete(String urlAsString){
  mPageFinishedLoading=true;
  URL currentUrl=mWebRenderer.getUrl();
  boolean equalUrl=currentUrl.toString().equals(urlAsString);
  if (!equalUrl) {
    try {
      URL url=new URL(urlAsString);
      if (url.getProtocol().equals(currentUrl.getProtocol()) && url.getHost().equals(currentUrl.getHost()) && url.getPath().equals(currentUrl.getPath())) {
        equalUrl=true;
      }
    }
 catch (    MalformedURLException e) {
    }
  }
  mWebRenderer.runPageInspector();
  if (equalUrl) {
    updateAppsForUrl(currentUrl);
    configureOpenInAppButton();
    configureOpenEmbedButton();
    configureArticleModeButton();
    mEventHandler.onPageLoaded(false);
    Log.e(TAG,"String_Node_Str" + urlAsString);
    String title=MainApplication.sTitleHashMap != null ? MainApplication.sTitleHashMap.get(urlAsString) : "String_Node_Str";
    if (TextUtils.isEmpty(title)) {
      if (mTitleTextView.getText() != null) {
        String currentTitle=mTitleTextView.getText().toString();
        if (currentTitle.equals(mLoadingString) == false) {
          title=currentTitle;
        }
      }
      if (title == null) {
        mTitleTextView.setText(null);
      }
    }
    if (!currentUrl.toString().equals(getContext().getString(R.string.empty_bubble_page))) {
      mAdapter.addUrlToAutoSuggestion(currentUrl.toString());
      MainApplication.saveUrlInHistory(getContext(),null,currentUrl.toString(),currentUrl.getHost(),title);
    }
 else {
      mTitleTextView.performClick();
    }
    postDelayed(mDelayedAutoContentDisplayLinkLoadedRunnable,Constant.AUTO_CONTENT_DISPLAY_DELAY);
    mWebRenderer.onPageLoadComplete();
  }
  mPageFinishedIgnoredUrl=null;
}

Fixed version (ground truth):
void onPageLoadComplete(String urlAsString){
  mPageFinishedLoading=true;
  URL currentUrl=mWebRenderer.getUrl();
  boolean equalUrl=currentUrl.toString().equals(urlAsString);
  if (!equalUrl) {
    try {
      URL url=new URL(urlAsString);
      if (url.getProtocol().equals(currentUrl.getProtocol()) && url.getHost().equals(currentUrl.getHost()) && url.getPath().equals(currentUrl.getPath())) {
        equalUrl=true;
      }
    }
 catch (    MalformedURLException e) {
    }
  }
  mWebRenderer.runPageInspector();
  if (equalUrl) {
    updateAppsForUrl(currentUrl);
    configureOpenInAppButton();
    configureOpenEmbedButton();
    configureArticleModeButton();
    mEventHandler.onPageLoaded(false);
    Log.e(TAG,"String_Node_Str" + urlAsString);
    String title=MainApplication.sTitleHashMap != null ? MainApplication.sTitleHashMap.get(urlAsString) : "String_Node_Str";
    if (TextUtils.isEmpty(title)) {
      if (mTitleTextView.getText() != null) {
        String currentTitle=mTitleTextView.getText().toString();
        if (currentTitle.equals(mLoadingString) == false) {
          title=currentTitle;
        }
      }
      if (title == null) {
        mTitleTextView.setText(null);
      }
    }
    if (!currentUrl.toString().equals(getContext().getString(R.string.empty_bubble_page))) {
      mAdapter.addUrlToAutoSuggestion(currentUrl.toString());
      MainApplication.saveUrlInHistory(getContext(),null,currentUrl.toString(),currentUrl.getHost(),title);
    }
 else {
      mTitleTextView.performClick();
    }
    postDelayed(mDelayedAutoContentDisplayLinkLoadedRunnable,Constant.AUTO_CONTENT_DISPLAY_DELAY);
    mWebRenderer.onPageLoadComplete();
    mWebRenderer.getView().requestFocus();
  }
  mPageFinishedIgnoredUrl=null;
}