Program: 29784
Project: 29784
Buggy source:
/** 
 * Parse XML sitemap page and show it
 * @param content	XML as a text
 * @return      void
 */
public void processContent(String content){
  DocumentBuilderFactory factory=DocumentBuilderFactory.newInstance();
  try {
    DocumentBuilder builder=factory.newDocumentBuilder();
    Document document;
    document=builder.parse(new ByteArrayInputStream(content.getBytes("String_Node_Str")));
    Node rootNode=document.getFirstChild();
    openHABWidgetDataSource.setSourceNode(rootNode);
    widgetList.clear();
    openHABWidgetAdapter.stopVideoWidgets();
    openHABWidgetAdapter.stopImageRefresh();
    for (    OpenHABWidget w : openHABWidgetDataSource.getWidgets()) {
      widgetList.add(w);
    }
    openHABWidgetAdapter.notifyDataSetChanged();
    setTitle(openHABWidgetDataSource.getTitle());
    setProgressBarIndeterminateVisibility(false);
    getListView().setSelection(0);
    getListView().setOnItemClickListener(new OnItemClickListener(){
      @Override public void onItemClick(      AdapterView<?> parent,      View view,      int position,      long id){
        Log.i(TAG,"String_Node_Str" + String.valueOf(position));
        OpenHABWidget openHABWidget=openHABWidgetAdapter.getItem(position);
        if (openHABWidget.hasLinkedPage()) {
          pageStack.add(0,new OpenHABPage(displayPageUrl,OpenHABWidgetListActivity.this.getListView().getFirstVisiblePosition()));
          displayPageUrl=openHABWidget.getLinkedPage().getLink();
          showPage(openHABWidget.getLinkedPage().getLink(),false);
        }
      }
    }
);
  }
 catch (  ParserConfigurationException e) {
    e.printStackTrace();
  }
catch (  UnsupportedEncodingException e) {
    e.printStackTrace();
  }
catch (  SAXException e) {
    e.printStackTrace();
  }
catch (  IOException e) {
    e.printStackTrace();
  }
  showPage(displayPageUrl,true);
}

Fixed version (ground truth):
/** 
 * Parse XML sitemap page and show it
 * @param content	XML as a text
 * @return      void
 */
public void processContent(String content){
  DocumentBuilderFactory factory=DocumentBuilderFactory.newInstance();
  try {
    DocumentBuilder builder=factory.newDocumentBuilder();
    Document document;
    document=builder.parse(new ByteArrayInputStream(content.getBytes("String_Node_Str")));
    Node rootNode=document.getFirstChild();
    openHABWidgetDataSource.setSourceNode(rootNode);
    widgetList.clear();
    openHABWidgetAdapter.stopVideoWidgets();
    openHABWidgetAdapter.stopImageRefresh();
    for (    OpenHABWidget w : openHABWidgetDataSource.getWidgets()) {
      widgetList.add(w);
    }
    openHABWidgetAdapter.notifyDataSetChanged();
    setTitle(openHABWidgetDataSource.getTitle());
    setProgressBarIndeterminateVisibility(false);
    getListView().setOnItemClickListener(new OnItemClickListener(){
      @Override public void onItemClick(      AdapterView<?> parent,      View view,      int position,      long id){
        Log.i(TAG,"String_Node_Str" + String.valueOf(position));
        OpenHABWidget openHABWidget=openHABWidgetAdapter.getItem(position);
        if (openHABWidget.hasLinkedPage()) {
          pageStack.add(0,new OpenHABPage(displayPageUrl,OpenHABWidgetListActivity.this.getListView().getFirstVisiblePosition()));
          displayPageUrl=openHABWidget.getLinkedPage().getLink();
          showPage(openHABWidget.getLinkedPage().getLink(),false);
        }
      }
    }
);
  }
 catch (  ParserConfigurationException e) {
    e.printStackTrace();
  }
catch (  UnsupportedEncodingException e) {
    e.printStackTrace();
  }
catch (  SAXException e) {
    e.printStackTrace();
  }
catch (  IOException e) {
    e.printStackTrace();
  }
  showPage(displayPageUrl,true);
}