Program: 29737
Project: 29737
Buggy source:
/** 
 * Loads data from sitemap page URL and passes it to processContent
 * @param pageUrl  an absolute base URL of openHAB sitemap page
 * @param longPolling  enable long polling when loading page
 * @return      void
 */
public void showPage(String pageUrl,final boolean longPolling){
  Log.i(TAG,"String_Node_Str" + pageUrl + "String_Node_Str"+ longPolling);
  if (!longPolling)   startProgressIndicator();
  List<BasicHeader> headers=new LinkedList<BasicHeader>();
  headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
  headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
  if (longPolling) {
    mAsyncHttpClient.setTimeout(300000);
    headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
    if (this.mAtmosphereTrackingId == null) {
      headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
    }
 else {
      headers.add(new BasicHeader("String_Node_Str",this.mAtmosphereTrackingId));
    }
  }
 else {
    headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
    mAsyncHttpClient.setTimeout(10000);
  }
  mAsyncHttpClient.get(mActivity,pageUrl,headers.toArray(new BasicHeader[]{}),null,new DocumentHttpResponseHandler(){
    @Override public void onSuccess(    int statusCode,    Header[] headers,    Document document){
      for (int i=0; i < headers.length; i++) {
        Log.i(TAG,headers[i].getName() + "String_Node_Str" + headers[i].getValue());
        if (headers[i].getName().equalsIgnoreCase("String_Node_Str")) {
          Log.i(TAG,"String_Node_Str" + headers[i].getValue());
          OpenHABWidgetListFragment.this.mAtmosphereTrackingId=headers[i].getValue();
        }
      }
      if (document != null) {
        Log.d(TAG,"String_Node_Str" + document.toString());
        if (!longPolling)         stopProgressIndicator();
        processContent(document,longPolling);
      }
 else {
        Log.e(TAG,"String_Node_Str");
        showPage(displayPageUrl,true);
      }
    }
    @Override public void onFailure(    Throwable error,    String content){
      mAtmosphereTrackingId=null;
      if (!longPolling)       stopProgressIndicator();
      if (error instanceof AsyncHttpAbortException) {
        Log.d(TAG,"String_Node_Str" + displayPageUrl + "String_Node_Str");
        return;
      }
      if (error instanceof SocketTimeoutException) {
        Log.d(TAG,"String_Node_Str");
        showPage(displayPageUrl,false);
        return;
      }
 else {
        Log.e(TAG,error.getClass().toString());
        Log.e(TAG,"String_Node_Str" + error.getClass().toString() + "String_Node_Str");
        networkHandler.removeCallbacks(networkRunnable);
        networkRunnable=new Runnable(){
          @Override public void run(){
            showPage(displayPageUrl,false);
          }
        }
;
        networkHandler.postDelayed(networkRunnable,10 * 1000);
      }
    }
  }
,mTag);
}

Fixed version (ground truth):
/** 
 * Loads data from sitemap page URL and passes it to processContent
 * @param pageUrl  an absolute base URL of openHAB sitemap page
 * @param longPolling  enable long polling when loading page
 * @return      void
 */
public void showPage(String pageUrl,final boolean longPolling){
  Log.i(TAG,"String_Node_Str" + pageUrl + "String_Node_Str"+ longPolling);
  if (!longPolling)   startProgressIndicator();
  List<BasicHeader> headers=new LinkedList<BasicHeader>();
  headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
  headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
  if (longPolling) {
    mAsyncHttpClient.setTimeout(300000);
    headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
    if (this.mAtmosphereTrackingId == null) {
      headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
    }
 else {
      headers.add(new BasicHeader("String_Node_Str",this.mAtmosphereTrackingId));
    }
  }
 else {
    headers.add(new BasicHeader("String_Node_Str","String_Node_Str"));
    mAsyncHttpClient.setTimeout(10000);
  }
  mAsyncHttpClient.get(mActivity,pageUrl,headers.toArray(new BasicHeader[]{}),null,new DocumentHttpResponseHandler(){
    @Override public void onSuccess(    int statusCode,    Header[] headers,    Document document){
      for (int i=0; i < headers.length; i++) {
        if (headers[i].getName().equalsIgnoreCase("String_Node_Str")) {
          Log.i(TAG,"String_Node_Str" + headers[i].getValue());
          OpenHABWidgetListFragment.this.mAtmosphereTrackingId=headers[i].getValue();
        }
      }
      if (document != null) {
        if (!longPolling)         stopProgressIndicator();
        processContent(document,longPolling);
      }
 else {
        Log.e(TAG,"String_Node_Str");
        showPage(displayPageUrl,true);
      }
    }
    @Override public void onFailure(    Throwable error,    String content){
      mAtmosphereTrackingId=null;
      if (!longPolling)       stopProgressIndicator();
      if (error instanceof AsyncHttpAbortException) {
        Log.d(TAG,"String_Node_Str" + displayPageUrl + "String_Node_Str");
        return;
      }
      if (error instanceof SocketTimeoutException) {
        Log.d(TAG,"String_Node_Str");
        showPage(displayPageUrl,false);
        return;
      }
 else {
        Log.e(TAG,error.getClass().toString());
        Log.e(TAG,"String_Node_Str" + error.getClass().toString() + "String_Node_Str");
        networkHandler.removeCallbacks(networkRunnable);
        networkRunnable=new Runnable(){
          @Override public void run(){
            showPage(displayPageUrl,false);
          }
        }
;
        networkHandler.postDelayed(networkRunnable,10 * 1000);
      }
    }
  }
,mTag);
}