Program: 138211
Project: 138211
Buggy source:
/** 
 * DOC xqliu Comment method "setInput".
 * @param objs
 */
public void setInput(Object[] objs){
  List<DBTableRepNode> tableNodeList=RepositoryNodeHelper.getTableNodeList(objs);
  List<DBViewRepNode> viewNodeList=RepositoryNodeHelper.getViewNodeList(objs);
  if (tableNodeList.size() == 0 && viewNodeList.size() == 0) {
    return;
  }
  List<RepositoryNode> setList=new ArrayList<RepositoryNode>();
  Connection tdProvider=null;
  for (  DBTableRepNode tableNode : tableNodeList) {
    if (tdProvider == null)     tdProvider=DataProviderHelper.getTdDataProvider(TableHelper.getParentCatalogOrSchema(tableNode.getTdTable()));
    if (tdProvider == null) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else     if (this.getAnalysis().getContext().getConnection() != null && !tdProvider.equals(this.getAnalysis().getContext().getConnection())) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else {
      setList.add(tableNode);
    }
  }
  for (  DBViewRepNode tableNode : viewNodeList) {
    if (tdProvider == null)     tdProvider=DataProviderHelper.getTdDataProvider(TableHelper.getParentCatalogOrSchema(tableNode.getTdView()));
    if (tdProvider == null) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else     if (this.getAnalysis().getContext().getConnection() != null && !tdProvider.equals(this.getAnalysis().getContext().getConnection())) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else {
      setList.add(tableNode);
    }
  }
  List<TableIndicator> tableIndicatorList=new ArrayList<TableIndicator>();
  for (  TableIndicator tableIndicator : tableIndicators) {
    if (setList.contains(tableIndicator.getColumnSet())) {
      tableIndicatorList.add(tableIndicator);
      setList.remove(tableIndicator.getColumnSet());
    }
  }
  for (  RepositoryNode set : setList) {
    TableIndicator tableIndicator=null;
    if (set instanceof DBViewRepNode) {
      tableIndicator=TableIndicator.createTableIndicatorWithRowCountIndicator(((DBViewRepNode)set).getTdView());
    }
 else     if (set instanceof DBTableRepNode) {
      tableIndicator=TableIndicator.createTableIndicatorWithRowCountIndicator(((DBTableRepNode)set).getTdTable());
    }
 else {
      continue;
    }
    tableIndicatorList.add(tableIndicator);
  }
  this.tableIndicators=tableIndicatorList.toArray(new TableIndicator[tableIndicatorList.size()]);
  this.setElements(tableIndicators);
}

Fixed version (ground truth):
/** 
 * DOC xqliu Comment method "setInput".
 * @param objs
 */
public void setInput(Object[] objs){
  List<DBTableRepNode> tableNodeList=RepositoryNodeHelper.getTableNodeList(objs);
  List<TableIndicator> tableIndicatorList=new ArrayList<TableIndicator>();
  List<DBViewRepNode> viewNodeList=RepositoryNodeHelper.getViewNodeList(objs);
  if (tableNodeList.size() == 0 && viewNodeList.size() == 0) {
    this.tableIndicators=tableIndicatorList.toArray(new TableIndicator[tableIndicatorList.size()]);
    this.setElements(tableIndicators);
    return;
  }
  List<RepositoryNode> setList=new ArrayList<RepositoryNode>();
  Connection tdProvider=null;
  for (  DBTableRepNode tableNode : tableNodeList) {
    if (tdProvider == null)     tdProvider=DataProviderHelper.getTdDataProvider(TableHelper.getParentCatalogOrSchema(tableNode.getTdTable()));
    if (tdProvider == null) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else     if (this.getAnalysis().getContext().getConnection() != null && !tdProvider.equals(this.getAnalysis().getContext().getConnection())) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else {
      setList.add(tableNode);
    }
  }
  for (  DBViewRepNode tableNode : viewNodeList) {
    if (tdProvider == null)     tdProvider=DataProviderHelper.getTdDataProvider(TableHelper.getParentCatalogOrSchema(tableNode.getTdView()));
    if (tdProvider == null) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else     if (this.getAnalysis().getContext().getConnection() != null && !tdProvider.equals(this.getAnalysis().getContext().getConnection())) {
      MessageUI.openError(DefaultMessagesImpl.getString("String_Node_Str",tableNode.getLabel()));
    }
 else {
      setList.add(tableNode);
    }
  }
  for (  TableIndicator tableIndicator : tableIndicators) {
    if (setList.contains(tableIndicator.getColumnSet())) {
      tableIndicatorList.add(tableIndicator);
      setList.remove(tableIndicator.getColumnSet());
    }
  }
  for (  RepositoryNode set : setList) {
    TableIndicator tableIndicator=null;
    if (set instanceof DBViewRepNode) {
      tableIndicator=TableIndicator.createTableIndicatorWithRowCountIndicator(((DBViewRepNode)set).getTdView());
    }
 else     if (set instanceof DBTableRepNode) {
      tableIndicator=TableIndicator.createTableIndicatorWithRowCountIndicator(((DBTableRepNode)set).getTdTable());
    }
 else {
      continue;
    }
    tableIndicatorList.add(tableIndicator);
  }
  this.tableIndicators=tableIndicatorList.toArray(new TableIndicator[tableIndicatorList.size()]);
  this.setElements(tableIndicators);
}