nus-yam/ex-repair huggingface dataset:
Program: 51983
Project: 51983
Buggy source:
public SwingScript(Element self,XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  try {
    if ((self.getAttributeValue("String_Node_Str") == null) || (self.getAttributeValue("String_Node_Str") == null)) {
      return;
    }
    domContainer.addEventHandler(self.getAttributeValue("String_Node_Str"),self.getAttributeValue("String_Node_Str"));
  }
 catch (  XulException e) {
    logger.error("String_Node_Str" + self.getAttributeValue("String_Node_Str") + "String_Node_Str"+ self.getAttributeValue("String_Node_Str"),e);
  }
}

Fixed version (ground truth):
public SwingScript(Element self,XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  try {
    if ((self.getAttributeValue("String_Node_Str") == null) || (self.getAttributeValue("String_Node_Str") == null)) {
      return;
    }
    domContainer.addEventHandler(self.getAttributeValue("String_Node_Str"),self.getAttributeValue("String_Node_Str"));
    logger.info("String_Node_Str" + self.getAttributeValue("String_Node_Str"));
  }
 catch (  XulException e) {
    logger.error("String_Node_Str" + self.getAttributeValue("String_Node_Str") + "String_Node_Str"+ self.getAttributeValue("String_Node_Str"),e);
  }
}
Program: 51984
Project: 51984
Buggy source:
public void setElements(Collection<T> elements){
}

Fixed version (ground truth):
public <T>void setElements(Collection<T> elements){
}
Program: 51985
Project: 51985
Buggy source:
public Collection<T> getElements(){
  return null;
}

Fixed version (ground truth):
public <T>Collection<T> getElements(){
  return null;
}
Program: 51986
Project: 51986
Buggy source:
public void clearSelection(){
  table.getSelectionModel().clearSelection();
}

Fixed version (ground truth):
public void clearSelection(){
  table.getSelectionModel().clearSelection();
  CellEditor ce=table.getCellEditor();
  if (ce != null) {
    ce.stopCellEditing();
  }
}
Program: 51987
Project: 51987
Buggy source:
public Collection<T> getElements(){
  return null;
}

Fixed version (ground truth):
public <T>Collection<T> getElements(){
  return null;
}
Program: 51990
Project: 51990
Buggy source:
public void setElements(Collection<T> elements){
  this.getRootChildren().removeAll();
  try {
    for (    T o : elements) {
      XulTreeRow row=this.getRootChildren().addNewRow();
      for (      XulComponent col : this.getColumns().getChildNodes()) {
        XulTreeCell cell=(XulTreeCell)getDocument().createElement("String_Node_Str");
        String attribute=((XulTreeCol)col).getBinding();
        String getter="String_Node_Str" + (String.valueOf(attribute.charAt(0)).toUpperCase()) + attribute.substring(1);
        cell.setLabel(new Expression(o,getter,null).getValue().toString());
        row.addCell(cell);
      }
    }
    table.updateUI();
  }
 catch (  XulException e) {
    logger.error("String_Node_Str",e);
  }
catch (  Exception e) {
    logger.error("String_Node_Str",e);
  }
}

Fixed version (ground truth):
public <T>void setElements(Collection<T> elements){
  this.getRootChildren().removeAll();
  logger.debug("String_Node_Str" + elements.size());
  try {
    for (    T o : elements) {
      XulTreeRow row=this.getRootChildren().addNewRow();
      for (      XulComponent col : this.getColumns().getChildNodes()) {
        XulTreeCell cell=(XulTreeCell)getDocument().createElement("String_Node_Str");
        String attribute=((XulTreeCol)col).getBinding();
        String getter="String_Node_Str" + (String.valueOf(attribute.charAt(0)).toUpperCase()) + attribute.substring(1);
        Object val=new Expression(o,getter,null).getValue();
        if (val != null) {
          cell.setLabel(val.toString());
        }
        row.addCell(cell);
      }
    }
    table.updateUI();
  }
 catch (  XulException e) {
    logger.error("String_Node_Str",e);
  }
catch (  Exception e) {
    logger.error("String_Node_Str",e);
  }
}
Program: 51992
Project: 51992
Buggy source:
/** 
 * @return int The maximum number of characters that the textbox allows to be entered.
 */
public int getMaxlength(){
  if (!textBox.isDisposed()) {
    maxLength=textBox.getTextLimit();
  }
  return maxLength;
}

Fixed version (ground truth):
/** 
 * @return int The maximum number of characters that the textbox allows to be entered.
 */
public int getMaxlength(){
  return maxLength;
}
Program: 51993
Project: 51993
Buggy source:
public void setColumns(XulTreeCols columns);

Fixed version (ground truth):
void setColumns(XulTreeCols columns);
Program: 51994
Project: 51994
Buggy source:
public void setDisabled(boolean dis);

Fixed version (ground truth):
void setDisabled(boolean dis);
Program: 51995
Project: 51995
Buggy source:
public void update();

Fixed version (ground truth):
void update();
Program: 51996
Project: 51996
Buggy source:
public int getRows();

Fixed version (ground truth):
int getRows();
Program: 51997
Project: 51997
Buggy source:
public int getWidth();

Fixed version (ground truth):
int getWidth();
Program: 51998
Project: 51998
Buggy source:
public XulTreeCols getColumns();

Fixed version (ground truth):
XulTreeCols getColumns();
Program: 51999
Project: 51999
Buggy source:
public boolean isEditable();

Fixed version (ground truth):
boolean isEditable();
Program: 52000
Project: 52000
Buggy source:
public void setRows(int rows);

Fixed version (ground truth):
void setRows(int rows);
Program: 52001
Project: 52001
Buggy source:
public int[] getSelectedRows();

Fixed version (ground truth):
int[] getSelectedRows();
Program: 52002
Project: 52002
Buggy source:
public void clearSelection();

Fixed version (ground truth):
void clearSelection();
Program: 52003
Project: 52003
Buggy source:
public void setOnedit(String onedit);

Fixed version (ground truth):
void setOnedit(String onedit);
Program: 52004
Project: 52004
Buggy source:
public boolean isDisabled();

Fixed version (ground truth):
boolean isDisabled();
Program: 52005
Project: 52005
Buggy source:
public void setEnableColumnDrag(boolean drag);

Fixed version (ground truth):
void setEnableColumnDrag(boolean drag);
Program: 52006
Project: 52006
Buggy source:
public void setRootChildren(XulTreeChildren rootChildren);

Fixed version (ground truth):
void setRootChildren(XulTreeChildren rootChildren);
Program: 52007
Project: 52007
Buggy source:
public void setActiveCellCoordinates(int row,int column);

Fixed version (ground truth):
void setActiveCellCoordinates(int row,int column);
Program: 52008
Project: 52008
Buggy source:
public Object getData();

Fixed version (ground truth):
Object getData();
Program: 52009
Project: 52009
Buggy source:
public String getOnedit();

Fixed version (ground truth):
String getOnedit();
Program: 52010
Project: 52010
Buggy source:
public XulTreeChildren getRootChildren();

Fixed version (ground truth):
XulTreeChildren getRootChildren();
Program: 52011
Project: 52011
Buggy source:
public int[] getActiveCellCoordinates();

Fixed version (ground truth):
int[] getActiveCellCoordinates();
Program: 52012
Project: 52012
Buggy source:
public Object[][] getValues();

Fixed version (ground truth):
Object[][] getValues();
Program: 52013
Project: 52013
Buggy source:
public String getSeltype();

Fixed version (ground truth):
String getSeltype();
Program: 52014
Project: 52014
Buggy source:
public void setData(Object data);

Fixed version (ground truth):
void setData(Object data);
Program: 52015
Project: 52015
Buggy source:
public void setElements(Collection<T> elements);

Fixed version (ground truth):
<T>void setElements(Collection<T> elements);
Program: 52016
Project: 52016
Buggy source:
public void addTreeRow(XulTreeRow row);

Fixed version (ground truth):
void addTreeRow(XulTreeRow row);
Program: 52017
Project: 52017
Buggy source:
public boolean isHierarchical();

Fixed version (ground truth):
boolean isHierarchical();
Program: 52018
Project: 52018
Buggy source:
public void removeTreeRows(int[] rows);

Fixed version (ground truth):
void removeTreeRows(int[] rows);
Program: 52019
Project: 52019
Buggy source:
public boolean isEnableColumnDrag();

Fixed version (ground truth):
boolean isEnableColumnDrag();
Program: 52020
Project: 52020
Buggy source:
public void setSelectedRows(int[] rows);

Fixed version (ground truth):
void setSelectedRows(int[] rows);
Program: 52021
Project: 52021
Buggy source:
public void setEditable(boolean edit);

Fixed version (ground truth):
void setEditable(boolean edit);
Program: 52022
Project: 52022
Buggy source:
public Collection<T> getElements();

Fixed version (ground truth):
<T>Collection<T> getElements();
Program: 52023
Project: 52023
Buggy source:
public String getOnselect();

Fixed version (ground truth):
String getOnselect();
Program: 52024
Project: 52024
Buggy source:
public void setOnselect(String select);

Fixed version (ground truth):
void setOnselect(String select);
Program: 52025
Project: 52025
Buggy source:
public void setSeltype(String type);

Fixed version (ground truth):
void setSeltype(String type);
Program: 52026
Project: 52026
Buggy source:
public void show(){
  if (dialog == null) {
    createDialog();
    dialog.pack();
  }
  dialog.setVisible(true);
}

Fixed version (ground truth):
public void show(){
  if (dialog == null) {
    createDialog();
    dialog.pack();
  }
  dialog.setLocationRelativeTo(frame);
  dialog.setVisible(true);
}
Program: 52030
Project: 52030
Buggy source:
public SwingGroupbox(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  this.orientation=Orient.VERTICAL;
  children=new ArrayList<XulComponent>();
  container=new JPanel(new GridBagLayout());
  container.setBorder(BorderFactory.createTitledBorder("String_Node_Str"));
  managedObject=container;
}

Fixed version (ground truth):
public SwingGroupbox(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  this.orientation=Orient.VERTICAL;
  children=new ArrayList<XulComponent>();
  container=new ScrollablePanel(new GridBagLayout());
  container.setBorder(BorderFactory.createTitledBorder("String_Node_Str"));
  managedObject=container;
}
Program: 52031
Project: 52031
Buggy source:
public SwingHbox(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  children=new ArrayList<XulComponent>();
  container=new JPanel(new GridBagLayout());
  managedObject=container;
  resetContainer();
}

Fixed version (ground truth):
public SwingHbox(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  children=new ArrayList<XulComponent>();
  container=new ScrollablePanel(new GridBagLayout());
  managedObject=container;
  resetContainer();
}
Program: 52032
Project: 52032
Buggy source:
public SwingVbox(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  this.orientation=Orient.VERTICAL;
  container=new JPanel(new GridBagLayout());
  managedObject=container;
  resetContainer();
}

Fixed version (ground truth):
public SwingVbox(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  this.orientation=Orient.VERTICAL;
  container=new ScrollablePanel(new GridBagLayout());
  managedObject=container;
  resetContainer();
}
Program: 52034
Project: 52034
Buggy source:
public String getValue(){
  return textField.getText();
}

Fixed version (ground truth):
public String getValue(){
  if (managedObject != null) {
    return ((JTextComponent)managedObject).getText();
  }
 else {
    logger.error("String_Node_Str");
    return null;
  }
}
Program: 52035
Project: 52035
Buggy source:
public Component getTableCellRendererComponent(JTable table,Object value,boolean isSelected,boolean hasFocus,int row,int column){
switch (col.getColumnType()) {
case CHECKBOX:
    JCheckBox checkbox=new JCheckBox();
  if (value instanceof String) {
    checkbox.setSelected(((String)value).equalsIgnoreCase("String_Node_Str"));
  }
 else {
    checkbox.setSelected((Boolean)value);
  }
return checkbox;
case COMBOBOX:
SwingTreeCell cell=(SwingTreeCell)rootChildren.getItem(row).getRow().getCell(SwingTree.this.columns.getChildNodes().indexOf(col));
JComboBox comboBox=null;
Vector data=(Vector)cell.getValue();
if (data == null) {
logger.debug("String_Node_Str" + value);
if (value instanceof Vector) {
data=(Vector)value;
}
}
if (data != null) {
comboBox=new JComboBox(data);
comboBox.setSelectedIndex(cell.getSelectedIndex());
}
 else {
comboBox=new JComboBox();
}
return comboBox;
default :
JLabel label=new JLabel((String)value);
return label;
}
}

Fixed version (ground truth):
public Component getTableCellRendererComponent(JTable table,Object value,boolean isSelected,boolean hasFocus,int row,int column){
switch (col.getColumnType()) {
case CHECKBOX:
    JCheckBox checkbox=new JCheckBox();
  if (value instanceof String) {
    checkbox.setSelected(((String)value).equalsIgnoreCase("String_Node_Str"));
  }
 else   if (value instanceof Boolean) {
    checkbox.setSelected((Boolean)value);
  }
 else   if (value == null) {
    checkbox.setSelected(false);
  }
return checkbox;
case COMBOBOX:
SwingTreeCell cell=(SwingTreeCell)rootChildren.getItem(row).getRow().getCell(SwingTree.this.columns.getChildNodes().indexOf(col));
JComboBox comboBox=null;
Vector data=(Vector)cell.getValue();
if (data == null) {
logger.debug("String_Node_Str" + value);
if (value instanceof Vector) {
data=(Vector)value;
}
}
if (data != null) {
comboBox=new JComboBox(data);
comboBox.setSelectedIndex(cell.getSelectedIndex());
}
 else {
comboBox=new JComboBox();
}
return comboBox;
default :
JLabel label=new JLabel((String)value);
return label;
}
}
Program: 52036
Project: 52036
Buggy source:
private TableCellRenderer getCellRenderer(final SwingTreeCol col){
  return new DefaultTableCellRenderer(){
    public Component getTableCellRendererComponent(    JTable table,    Object value,    boolean isSelected,    boolean hasFocus,    int row,    int column){
switch (col.getColumnType()) {
case CHECKBOX:
        JCheckBox checkbox=new JCheckBox();
      if (value instanceof String) {
        checkbox.setSelected(((String)value).equalsIgnoreCase("String_Node_Str"));
      }
 else {
        checkbox.setSelected((Boolean)value);
      }
    return checkbox;
case COMBOBOX:
  SwingTreeCell cell=(SwingTreeCell)rootChildren.getItem(row).getRow().getCell(SwingTree.this.columns.getChildNodes().indexOf(col));
JComboBox comboBox=null;
Vector data=(Vector)cell.getValue();
if (data == null) {
logger.debug("String_Node_Str" + value);
if (value instanceof Vector) {
data=(Vector)value;
}
}
if (data != null) {
comboBox=new JComboBox(data);
comboBox.setSelectedIndex(cell.getSelectedIndex());
}
 else {
comboBox=new JComboBox();
}
return comboBox;
default :
JLabel label=new JLabel((String)value);
return label;
}
}
}
;
}

Fixed version (ground truth):
private TableCellRenderer getCellRenderer(final SwingTreeCol col){
  return new DefaultTableCellRenderer(){
    public Component getTableCellRendererComponent(    JTable table,    Object value,    boolean isSelected,    boolean hasFocus,    int row,    int column){
switch (col.getColumnType()) {
case CHECKBOX:
        JCheckBox checkbox=new JCheckBox();
      if (value instanceof String) {
        checkbox.setSelected(((String)value).equalsIgnoreCase("String_Node_Str"));
      }
 else       if (value instanceof Boolean) {
        checkbox.setSelected((Boolean)value);
      }
 else       if (value == null) {
        checkbox.setSelected(false);
      }
    return checkbox;
case COMBOBOX:
  SwingTreeCell cell=(SwingTreeCell)rootChildren.getItem(row).getRow().getCell(SwingTree.this.columns.getChildNodes().indexOf(col));
JComboBox comboBox=null;
Vector data=(Vector)cell.getValue();
if (data == null) {
logger.debug("String_Node_Str" + value);
if (value instanceof Vector) {
data=(Vector)value;
}
}
if (data != null) {
comboBox=new JComboBox(data);
comboBox.setSelectedIndex(cell.getSelectedIndex());
}
 else {
comboBox=new JComboBox();
}
return comboBox;
default :
JLabel label=new JLabel((String)value);
return label;
}
}
}
;
}
Program: 52037
Project: 52037
Buggy source:
@Override public Component getTableCellEditorComponent(JTable table,Object value,boolean isSelected,final int row,final int column){
switch (col.getColumnType()) {
case CHECKBOX:
    final JCheckBox checkbox=new JCheckBox();
  checkbox.addActionListener(new ActionListener(){
    public void actionPerformed(    ActionEvent event){
      SwingTree.this.table.setValueAt(checkbox.isSelected(),row,column);
    }
  }
);
control=checkbox;
if (value instanceof String) {
checkbox.setSelected(((String)value).equalsIgnoreCase("String_Node_Str"));
}
 else {
checkbox.setSelected((Boolean)value);
}
return checkbox;
case COMBOBOX:
final JComboBox comboBox=new JComboBox((Vector)value);
comboBox.addActionListener(new ActionListener(){
public void actionPerformed(ActionEvent event){
SwingTree.logger.debug("String_Node_Str" + comboBox.getSelectedItem() + "String_Node_Str"+ row+ "String_Node_Str"+ column);
SwingTree.this.table.setValueAt(comboBox.getSelectedItem(),row,column);
}
}
);
control=comboBox;
return comboBox;
default :
final JTextField label=new JTextField((String)value);
label.getDocument().addDocumentListener(new DocumentListener(){
public void changedUpdate(DocumentEvent arg0){
SwingTree.this.table.setValueAt(label.getText(),row,column);
}
public void insertUpdate(DocumentEvent arg0){
SwingTree.this.table.setValueAt(label.getText(),row,column);
}
public void removeUpdate(DocumentEvent arg0){
SwingTree.this.table.setValueAt(label.getText(),row,column);
}
}
);
control=label;
return label;
}
}

Fixed version (ground truth):
@Override public Component getTableCellEditorComponent(JTable table,Object value,boolean isSelected,final int row,final int column){
switch (col.getColumnType()) {
case CHECKBOX:
    final JCheckBox checkbox=new JCheckBox();
  checkbox.addActionListener(new ActionListener(){
    public void actionPerformed(    ActionEvent event){
      SwingTree.this.table.setValueAt(checkbox.isSelected(),row,column);
    }
  }
);
control=checkbox;
if (value instanceof String) {
checkbox.setSelected(((String)value).equalsIgnoreCase("String_Node_Str"));
}
 else if (value instanceof Boolean) {
checkbox.setSelected((Boolean)value);
}
 else if (value == null) {
checkbox.setSelected(false);
}
return checkbox;
case COMBOBOX:
final JComboBox comboBox=new JComboBox((Vector)value);
comboBox.addActionListener(new ActionListener(){
public void actionPerformed(ActionEvent event){
SwingTree.logger.debug("String_Node_Str" + comboBox.getSelectedItem() + "String_Node_Str"+ row+ "String_Node_Str"+ column);
SwingTree.this.table.setValueAt(comboBox.getSelectedItem(),row,column);
}
}
);
control=comboBox;
return comboBox;
default :
final JTextField label=new JTextField((String)value);
label.getDocument().addDocumentListener(new DocumentListener(){
public void changedUpdate(DocumentEvent arg0){
SwingTree.this.table.setValueAt(label.getText(),row,column);
}
public void insertUpdate(DocumentEvent arg0){
SwingTree.this.table.setValueAt(label.getText(),row,column);
}
public void removeUpdate(DocumentEvent arg0){
SwingTree.this.table.setValueAt(label.getText(),row,column);
}
}
);
control=label;
return label;
}
}
Program: 52039
Project: 52039
Buggy source:
public Object[][] getValues(){
  TableModel model=table.getModel();
  Object[][] data=new Object[model.getRowCount()][model.getColumnCount()];
  int y=0;
  for (  XulComponent item : this.rootChildren.getChildNodes()) {
    int x=0;
    for (    XulComponent tempCell : ((XulTreeItem)item).getRow().getChildNodes()) {
      SwingTreeCell cell=(SwingTreeCell)tempCell;
switch (columns.getColumn(x).getColumnType()) {
case CHECKBOX:
        data[y][x]=cell.getValue();
      break;
case COMBOBOX:
    Vector values=(Vector)cell.getValue();
  int idx=cell.getSelectedIndex();
data[y][x]=values.get(idx);
break;
default :
data[y][x]=cell.getLabel();
break;
}
x++;
}
y++;
}
return data;
}

Fixed version (ground truth):
public Object[][] getValues(){
  TableModel model=table.getModel();
  Object[][] data=new Object[this.rootChildren.getChildNodes().size()][model.getColumnCount()];
  int y=0;
  for (  XulComponent item : this.rootChildren.getChildNodes()) {
    int x=0;
    for (    XulComponent tempCell : ((XulTreeItem)item).getRow().getChildNodes()) {
      SwingTreeCell cell=(SwingTreeCell)tempCell;
switch (columns.getColumn(x).getColumnType()) {
case CHECKBOX:
        data[y][x]=cell.getValue();
      break;
case COMBOBOX:
    Vector values=(Vector)cell.getValue();
  int idx=cell.getSelectedIndex();
data[y][x]=values.get(idx);
break;
default :
data[y][x]=cell.getLabel();
break;
}
x++;
}
y++;
}
return data;
}
Program: 52040
Project: 52040
Buggy source:
@Override public void layout(){
}

Fixed version (ground truth):
@Override public void layout(){
  for (  XulComponent comp : this.children) {
    if (comp instanceof XulTreeRow) {
      this.row=(SwingTreeRow)comp;
    }
 else {
      logger.error("String_Node_Str");
    }
  }
}
Program: 52041
Project: 52041
Buggy source:
public SwingRadioGroup(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  container=new JPanel(new GridBagLayout());
  managedObject=container;
  resetContainer();
}

Fixed version (ground truth):
public SwingRadioGroup(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  this.orientation=Orient.VERTICAL;
  container=new JPanel(new GridBagLayout());
  managedObject=container;
  resetContainer();
}
Program: 52042
Project: 52042
Buggy source:
@Override public Object getManagedObject(){
  if (managedObject == null) {
    if (this.multiline) {
      textArea=new JTextArea();
      managedObject=textArea;
      scrollPane=new JScrollPane(textArea);
      this.scrollPane.setMinimumSize(new Dimension(this.width,this.height));
      this.scrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
    }
 else {
      textField=new JTextField();
      managedObject=textField;
    }
  }
  return (this.multiline) ? scrollPane : textField;
}

Fixed version (ground truth):
@Override public Object getManagedObject(){
  if (managedObject == null) {
    if (this.multiline) {
      textArea=new JTextArea((value != null) ? value : "String_Node_Str");
      managedObject=textArea;
      scrollPane=new JScrollPane(textArea);
      this.scrollPane.setMinimumSize(new Dimension(this.width,this.height));
      this.scrollPane.setHorizontalScrollBarPolicy(ScrollPaneConstants.HORIZONTAL_SCROLLBAR_NEVER);
    }
 else {
      textField=new JTextField((value != null) ? value : "String_Node_Str");
      textField.setPreferredSize(new Dimension(200,20));
      managedObject=textField;
    }
  }
  return (this.multiline) ? scrollPane : textField;
}
Program: 52043
Project: 52043
Buggy source:
public SwingTree(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  XulComponent primaryColumn=getElementByXPath("String_Node_Str");
  XulComponent isaContainer=getElementByXPath("String_Node_Str");
  isHierarchical=(primaryColumn != null) && (isaContainer != null);
  if (isHierarchical) {
    tree=new JTree();
  }
 else {
    table=new JTable();
  }
  ToolTipManager.sharedInstance().unregisterComponent(table);
  ToolTipManager.sharedInstance().unregisterComponent(table.getTableHeader());
  scrollpane=new JScrollPane(table);
  this.managedObject=scrollpane.getViewport();
}

Fixed version (ground truth):
public SwingTree(XulComponent parent,XulDomContainer domContainer,String tagName){
  super("String_Node_Str");
  XulComponent primaryColumn=getElementByXPath("String_Node_Str");
  XulComponent isaContainer=getElementByXPath("String_Node_Str");
  isHierarchical=(primaryColumn != null) && (isaContainer != null);
  if (isHierarchical) {
    tree=new JTree();
  }
 else {
    table=new JTable();
  }
  ToolTipManager.sharedInstance().unregisterComponent(table);
  ToolTipManager.sharedInstance().unregisterComponent(table.getTableHeader());
  table.setRowHeight(18);
  scrollpane=new JScrollPane(table);
  this.managedObject=scrollpane.getViewport();
}
Program: 52044
Project: 52044
Buggy source:
public Object[][] getValues(){
  TableModel model=table.getModel();
  Object[][] data=new Object[this.rootChildren.getChildNodes().size()][model.getColumnCount()];
  int y=0;
  for (  XulComponent item : this.rootChildren.getChildNodes()) {
    int x=0;
    for (    XulComponent tempCell : ((XulTreeItem)item).getRow().getChildNodes()) {
      SwingTreeCell cell=(SwingTreeCell)tempCell;
switch (columns.getColumn(x).getColumnType()) {
case CHECKBOX:
        data[y][x]=cell.getValue();
      break;
case COMBOBOX:
    Vector values=(Vector)cell.getValue();
  int idx=cell.getSelectedIndex();
data[y][x]=values.get(idx);
break;
default :
data[y][x]=cell.getLabel();
break;
}
x++;
}
y++;
}
return data;
}

Fixed version (ground truth):
public Object[][] getValues(){
  TableModel model=table.getModel();
  Object[][] data=new Object[this.rootChildren.getChildNodes().size()][model.getColumnCount()];
  int y=0;
  for (  XulComponent item : this.rootChildren.getChildNodes()) {
    int x=0;
    for (    XulComponent tempCell : ((XulTreeItem)item).getRow().getChildNodes()) {
      SwingTreeCell cell=(SwingTreeCell)tempCell;
switch (columns.getColumn(x).getColumnType()) {
case CHECKBOX:
        Boolean flag=(Boolean)cell.getValue();
      if (flag == null) {
        flag=Boolean.FALSE;
      }
    data[y][x]=flag;
  break;
case COMBOBOX:
Vector values=(Vector)cell.getValue();
int idx=cell.getSelectedIndex();
data[y][x]=values.get(idx);
break;
default :
data[y][x]=cell.getLabel();
break;
}
x++;
}
y++;
}
return data;
}
Program: 52046
Project: 52046
Buggy source:
public static void main(String[] args){
  Card player1[]=new Card[5];
  Card player2[]=new Card[5];
  player1[0]=new Card(3,0);
  player1[1]=new Card(2,0);
  player1[2]=new Card(2,1);
  player1[3]=new Card(6,0);
  player1[4]=new Card(6,1);
  player2[0]=new Card(4,0);
  player2[1]=new Card(2,0);
  player2[2]=new Card(2,1);
  player2[3]=new Card(6,0);
  player2[4]=new Card(6,1);
  System.out.println("String_Node_Str");
  for (int i=0; i < 5; i++)   System.out.println(player1[i].toWords());
  System.out.println();
  System.out.println("String_Node_Str");
  for (int i=0; i < 5; i++)   System.out.println(player2[i].toWords());
  System.out.println();
  HandEvaluator he=new HandEvaluator(player1);
  System.out.println("String_Node_Str" + he.getPokerHandAsString() + "String_Node_Str"+ he.getPokerHandAsValued());
  double p1Value=he.getPokerHandAsValued();
  he=new HandEvaluator(player2);
  System.out.println("String_Node_Str" + he.getPokerHandAsString() + "String_Node_Str"+ he.getPokerHandAsValued());
  double p2Value=he.getPokerHandAsValued();
  if (p1Value > p2Value) {
    System.out.println("String_Node_Str");
  }
 else   if (p2Value > p1Value) {
    System.out.println("String_Node_Str");
  }
 else {
    System.out.println("String_Node_Str");
  }
}

Fixed version (ground truth):
public static void main(String[] args){
  Card player1[]=new Card[5];
  Card player2[]=new Card[5];
  player1[0]=new Card(3,0);
  player1[1]=new Card(3,1);
  player1[2]=new Card(3,2);
  player1[3]=new Card(3,3);
  player1[4]=new Card(6,1);
  player2[0]=new Card(3,0);
  player2[1]=new Card(3,1);
  player2[2]=new Card(3,2);
  player2[3]=new Card(3,3);
  player2[4]=new Card(7,1);
  System.out.println("String_Node_Str");
  for (int i=0; i < 5; i++)   System.out.println(player1[i].toWords());
  System.out.println();
  System.out.println("String_Node_Str");
  for (int i=0; i < 5; i++)   System.out.println(player2[i].toWords());
  System.out.println();
  HandEvaluator he=new HandEvaluator(player1);
  System.out.println("String_Node_Str" + he.getPokerHandAsString() + "String_Node_Str"+ he.getPokerHandAsValued());
  double p1Value=he.getPokerHandAsValued();
  he=new HandEvaluator(player2);
  System.out.println("String_Node_Str" + he.getPokerHandAsString() + "String_Node_Str"+ he.getPokerHandAsValued());
  double p2Value=he.getPokerHandAsValued();
  if (p1Value > p2Value) {
    System.out.println("String_Node_Str");
  }
 else   if (p2Value > p1Value) {
    System.out.println("String_Node_Str");
  }
 else {
    System.out.println("String_Node_Str");
  }
}
Program: 52047
Project: 52047
Buggy source:
/** 
 * sortedCardValues  1 to 13
 */
public float calcAddValue(List<Byte> sortedCardValues,int rate,int exclude1,int exclude2){
  float tempRank=0;
  for (int i=4; i >= 0; i--) {
    if (sortedCardValues.get(i) == exclude1 || sortedCardValues.get(i) == exclude2)     continue;
    tempRank+=(float)sortedCardValues.get(i) / rate;
    rate*=100;
  }
  return tempRank;
}

Fixed version (ground truth):
/** 
 * sortedCardValues  1 to 13
 */
public double calcAddValue(List<Byte> sortedCardValues,int rate,int exclude1,int exclude2){
  double tempRank=0;
  for (int i=4; i >= 0; i--) {
    if (sortedCardValues.get(i) == exclude1 || sortedCardValues.get(i) == exclude2)     continue;
    tempRank+=(float)sortedCardValues.get(i) / rate;
    rate*=100;
  }
  return tempRank;
}
Program: 52049
Project: 52049
Buggy source:
public static Result findMementos(){
  Form<Query> urlParam=queryForm.bindFromRequest();
  System.err.println("String_Node_Str" + urlParam.hasErrors());
  if (urlParam.hasErrors()) {
    return badRequest(views.html.search.render(new MementoBackingBean(),urlParam));
  }
  Query q=urlParam.get();
  return redirect(routes.Application.findMementosFor(q.url));
}

Fixed version (ground truth):
public static Result findMementos(){
  Form<Query> urlParam=queryForm.bindFromRequest();
  if (urlParam.hasErrors()) {
    return badRequest(views.html.search.render(new MementoQuery(),urlParam));
  }
  Query q=urlParam.get();
  return redirect(routes.Application.findMementosFor(q.url));
}
Program: 52050
Project: 52050
Buggy source:
public static Result queryMementos(){
  return ok(views.html.search.render(new MementoBackingBean(),queryForm));
}

Fixed version (ground truth):
public static Result queryMementos(){
  return ok(views.html.search.render(new MementoQuery(),queryForm));
}
Program: 52051
Project: 52051
Buggy source:
public static Result findMementosFor(String url){
  MementoBackingBean msb=(MementoBackingBean)Cache.get("String_Node_Str" + url);
  if (msb == null) {
    msb=new MementoBackingBean();
    msb.setUrl(url);
  }
  Cache.set("String_Node_Str" + url,msb);
  Query q=new Query();
  q.url=url;
  return ok(views.html.search.render(msb,queryForm.fill(q)));
}

Fixed version (ground truth):
public static Result findMementosFor(String url){
  MementoQuery msb=(MementoQuery)Cache.get("String_Node_Str" + url);
  if (msb == null) {
    msb=new MementoQuery();
    Logger.info("String_Node_Str" + url);
    msb.setUrl(url);
  }
  Cache.set("String_Node_Str" + url,msb);
  if (msb.getErrorMessage() != null)   flash("String_Node_Str",msb.getErrorMessage());
  Query q=new Query();
  q.url=url;
  return ok(views.html.search.render(msb,queryForm.fill(q)));
}
Program: 52052
Project: 52052
Buggy source:
void updateWidgets(){
  ComponentName thisWidget=new ComponentName(this,SleepTimerWidgetProvider.class);
  AppWidgetManager manager=AppWidgetManager.getInstance(this);
  RemoteViews remoteView;
  if (UnlockTools.isAppPayed(this)) {
    remoteView=getUnlockedRemoteView();
  }
 else {
    remoteView=getLockedRemoteView();
  }
  manager.updateAppWidget(thisWidget,remoteView);
}

Fixed version (ground truth):
void updateWidgets(){
  ComponentName thisWidget=new ComponentName(this,SleepTimerWidgetProvider.class);
  AppWidgetManager manager=AppWidgetManager.getInstance(this);
  RemoteViews remoteView;
  if (UnlockTools.isAppPayed(this)) {
    remoteView=getUnlockedRemoteView();
  }
 else {
    remoteView=getLockedRemoteView();
  }
  try {
    manager.updateAppWidget(thisWidget,remoteView);
  }
 catch (  NullPointerException e) {
    BugSender.sendBug(this,"String_Node_Str","String_Node_Str");
  }
}
Program: 52053
Project: 52053
Buggy source:
@Override public IPath instanceDirectory(String instanceName){
  return getRuntime().getLocation().append(instanceName);
}

Fixed version (ground truth):
@Override public IPath instanceDirectory(String instanceName){
  return defaultInstancesDirectory().append(instanceName);
}
Program: 52054
Project: 52054
Buggy source:
public static IPath getTcServerRuntimePath(IPath installPath){
  File[] files=installPath.toFile().listFiles(new FilenameFilter(){
    @Override public boolean accept(    File dir,    String name){
      return Pattern.matches("String_Node_Str",name) && new File(dir,name).isDirectory();
    }
  }
);
  return files.length > 0 ? Path.fromOSString(files[0].toString()) : null;
}

Fixed version (ground truth):
public static IPath getTcServerRuntimePath(IPath installPath){
  File[] files=installPath.toFile().listFiles(new FilenameFilter(){
    @Override public boolean accept(    File dir,    String name){
      return (Pattern.matches("String_Node_Str",name) || Pattern.matches("String_Node_Str",name)) && new File(dir,name).isDirectory();
    }
  }
);
  return files.length > 0 ? Path.fromOSString(files[0].toString()) : null;
}
Program: 52055
Project: 52055
Buggy source:
@Override public boolean accept(File dir,String name){
  return Pattern.matches("String_Node_Str",name) && new File(dir,name).isDirectory();
}

Fixed version (ground truth):
@Override public boolean accept(File dir,String name){
  return (Pattern.matches("String_Node_Str",name) || Pattern.matches("String_Node_Str",name)) && new File(dir,name).isDirectory();
}
Program: 52056
Project: 52056
Buggy source:
public static File getInstanceDirectory(ServerWorkingCopy wc){
  if (wc != null) {
    String instanceDir=wc.getAttribute(TomcatServer.PROPERTY_INSTANCE_DIR,(String)null);
    if (instanceDir != null) {
      File file=new File(instanceDir);
      if (file.exists()) {
        return file;
      }
    }
    String serverName=wc.getAttribute(TcServer.KEY_SERVER_NAME,(String)null);
    if (serverName != null) {
      IPath path=wc.getRuntime().getLocation();
      File directory=path.toFile();
      if (directory.exists()) {
        File file=new File(directory,serverName);
        if (file.exists()) {
          return file;
        }
      }
    }
  }
  return null;
}

Fixed version (ground truth):
public static File getInstanceDirectory(ServerWorkingCopy wc){
  if (wc != null) {
    String instanceDir=wc.getAttribute(TomcatServer.PROPERTY_INSTANCE_DIR,(String)null);
    if (instanceDir != null) {
      File file=new File(instanceDir);
      if (file.exists()) {
        return file;
      }
    }
    String serverName=wc.getAttribute(TcServer.KEY_SERVER_NAME,(String)null);
    if (serverName != null) {
      ITcRuntime tcRuntime=getTcRuntime(wc.getRuntime());
      IPath path=tcRuntime == null ? wc.getRuntime().getLocation() : tcRuntime.instanceDirectory(serverName);
      File directory=path.toFile();
      if (directory.exists()) {
        return directory;
      }
    }
  }
  return null;
}
Program: 52057
Project: 52057
Buggy source:
private void initialize(){
  isDefaultServerName=wc == null || TcServerUtil.isTcServerDefaultName(wc);
  existingInstanceButton.setEnabled(false);
  if (wc != null && serverNameCombo != null) {
    String previous=serverNameCombo.getText();
    serverNameCombo.removeAll();
    IPath path=wc.getRuntime().getLocation();
    File file=path.toFile();
    if (file.exists()) {
      File[] serverDirectories=file.listFiles();
      if (serverDirectories != null) {
        for (        File directory : serverDirectories) {
          if (directory.isDirectory() && new File(directory,"String_Node_Str").exists()) {
            serverNameCombo.add(directory.getName());
          }
        }
      }
    }
    existingInstanceButton.setEnabled(true);
    serverNameCombo.setText(previous);
  }
}

Fixed version (ground truth):
private void initialize(){
  isDefaultServerName=wc == null || TcServerUtil.isTcServerDefaultName(wc);
  existingInstanceButton.setEnabled(false);
  if (wc != null && serverNameCombo != null) {
    String previous=serverNameCombo.getText();
    serverNameCombo.removeAll();
    ITcRuntime tcRuntime=TcServerUtil.getTcRuntime(wc.getRuntime());
    if (tcRuntime != null) {
      IPath instancesDirectory=tcRuntime.defaultInstancesDirectory();
      File[] serverDirectories=instancesDirectory.toFile().listFiles();
      if (serverDirectories != null) {
        for (        File directory : serverDirectories) {
          if (directory.isDirectory() && new File(directory,"String_Node_Str").exists()) {
            serverNameCombo.add(directory.getName());
          }
        }
      }
    }
    existingInstanceButton.setEnabled(true);
    serverNameCombo.setText(previous);
  }
}
Program: 52058
Project: 52058
Buggy source:
private static File getInstanceDirectory(String[] arguments,String instanceName){
  for (int i=0; i < arguments.length; i++) {
    if (arguments[i].equals("String_Node_Str") && arguments[i + 1] != null) {
      return new File(arguments[i + 1],instanceName);
    }
  }
  return null;
}

Fixed version (ground truth):
public static File getInstanceDirectory(ServerWorkingCopy wc){
  if (wc != null) {
    String instanceDir=wc.getAttribute(TomcatServer.PROPERTY_INSTANCE_DIR,(String)null);
    if (instanceDir != null) {
      File file=new File(instanceDir);
      if (file.exists()) {
        return file;
      }
    }
    String serverName=wc.getAttribute(TcServer.KEY_SERVER_NAME,(String)null);
    if (serverName != null) {
      IPath path=wc.getRuntime().getLocation();
      File directory=path.toFile();
      if (directory.exists()) {
        File file=new File(directory,serverName);
        if (file.exists()) {
          return file;
        }
      }
    }
  }
  return null;
}
Program: 52059
Project: 52059
Buggy source:
private void updateDescription(IStatus status){
  if (status.isOK() && existingInstanceButton != null && existingInstanceButton.getSelection()) {
    File directory=getInstanceDirectory();
    if (directory != null) {
      File libDirectory=new File(directory,"String_Node_Str");
      if (new File(libDirectory,"String_Node_Str").exists()) {
        descriptionLabel.setText("String_Node_Str");
      }
 else {
        descriptionLabel.setText("String_Node_Str");
      }
      return;
    }
  }
  descriptionLabel.setText("String_Node_Str");
}

Fixed version (ground truth):
private void updateDescription(IStatus status){
  if (status.isOK() && existingInstanceButton != null && existingInstanceButton.getSelection()) {
    File directory=TcServerUtil.getInstanceDirectory((ServerWorkingCopy)wc);
    if (directory != null) {
      File libDirectory=new File(directory,"String_Node_Str");
      if (new File(libDirectory,"String_Node_Str").exists()) {
        descriptionLabel.setText("String_Node_Str");
      }
 else {
        descriptionLabel.setText("String_Node_Str");
      }
      return;
    }
  }
  descriptionLabel.setText("String_Node_Str");
}
Program: 52060
Project: 52060
Buggy source:
private void initialize(){
  existingInstanceButton.setEnabled(false);
  if (wc != null && serverNameCombo != null) {
    serverNameCombo.removeAll();
    IPath path=wc.getRuntime().getLocation();
    File file=new File(path.toFile(),SERVER_PATH);
    if (file.exists()) {
      File[] serverDirectories=file.listFiles();
      if (serverDirectories != null) {
        for (        File directory : serverDirectories) {
          if (directory.isDirectory() && new File(directory,"String_Node_Str").exists()) {
            serverNameCombo.add(directory.getName());
          }
        }
      }
    }
    existingInstanceButton.setEnabled(true);
  }
}

Fixed version (ground truth):
private void initialize(){
  existingInstanceButton.setEnabled(false);
  if (wc != null && serverNameCombo != null) {
    serverNameCombo.removeAll();
    IPath path=wc.getRuntime().getLocation();
    File file=path.toFile();
    if (file.exists()) {
      File[] serverDirectories=file.listFiles();
      if (serverDirectories != null) {
        for (        File directory : serverDirectories) {
          if (directory.isDirectory() && new File(directory,"String_Node_Str").exists()) {
            serverNameCombo.add(directory.getName());
          }
        }
      }
    }
    existingInstanceButton.setEnabled(true);
  }
}
Program: 52061
Project: 52061
Buggy source:
private IStatus doValidate(){
  if (newInstanceButton != null && newInstanceButton.getSelection()) {
    return Status.OK_STATUS;
  }
  if (((ServerWorkingCopy)wc).getAttribute(TcServer.KEY_SERVER_NAME,(String)null) == null && ((ServerWorkingCopy)wc).getAttribute(ITomcatServer.PROPERTY_INSTANCE_DIR,(String)null) == null) {
    return new Status(IStatus.INFO,ITcServerConstants.PLUGIN_ID,SELECT_INSTANCE_MESSAGE);
  }
  String tomcatVersion=TcServerUtil.getServerVersion(wc.getRuntime());
  if (tomcatVersion == null) {
    return new Status(IStatus.ERROR,ITcServerConstants.PLUGIN_ID,ILNVALID_SERVER_RUNTIME_SELECTED);
  }
  File file=getInstanceDirectory();
  if (file != null && file.exists()) {
    IStatus status=TcServerUtil.validateInstance(file,true);
    String instanceTomcatVersion=TcServerUtil.getInstanceTomcatVersion(file);
    if (status.isOK() && instanceTomcatVersion == null) {
      status=new Status(IStatus.WARNING,ITcServerConstants.PLUGIN_ID,UNKNOWN_INSTANCE_TOMCAT_VERSION);
    }
    if (status.isOK() && !tomcatVersion.equals(instanceTomcatVersion)) {
      status=new Status(IStatus.WARNING,ITcServerConstants.PLUGIN_ID,MessageFormat.format(TOMCAT_VERSION_MISMATCH,tomcatVersion,instanceTomcatVersion));
    }
    return status;
  }
  return new Status(IStatus.ERROR,ITcServerConstants.PLUGIN_ID,SERVER_DOES_NOT_EXIST_MESSAGE);
}

Fixed version (ground truth):
private IStatus doValidate(){
  if (newInstanceButton != null && newInstanceButton.getSelection()) {
    return Status.OK_STATUS;
  }
  ServerWorkingCopy workingCopy=(ServerWorkingCopy)wc;
  if (workingCopy.getAttribute(TcServer.KEY_SERVER_NAME,(String)null) == null && workingCopy.getAttribute(ITomcatServer.PROPERTY_INSTANCE_DIR,(String)null) == null) {
    return new Status(IStatus.INFO,ITcServerConstants.PLUGIN_ID,SELECT_INSTANCE_MESSAGE);
  }
  String tomcatVersion=TcServerUtil.getServerVersion(wc.getRuntime());
  if (tomcatVersion == null) {
    return new Status(IStatus.ERROR,ITcServerConstants.PLUGIN_ID,ILNVALID_SERVER_RUNTIME_SELECTED);
  }
  File file=TcServerUtil.getInstanceDirectory(workingCopy);
  if (file != null && file.exists()) {
    IStatus status=TcServerUtil.validateInstance(file,true);
    String instanceTomcatVersion=TcServerUtil.getInstanceTomcatVersion(file);
    if (status.isOK() && instanceTomcatVersion == null) {
      status=new Status(IStatus.ERROR,ITcServerConstants.PLUGIN_ID,Messages.UNKNOWN_INSTANCE_TOMCAT_VERSION);
    }
    if (status.isOK() && !tomcatVersion.equals(instanceTomcatVersion)) {
      status=new Status(IStatus.WARNING,ITcServerConstants.PLUGIN_ID,MessageFormat.format(Messages.TOMCAT_VERSION_MISMATCH,tomcatVersion,instanceTomcatVersion));
    }
    return status;
  }
  return new Status(IStatus.ERROR,ITcServerConstants.PLUGIN_ID,SERVER_DOES_NOT_EXIST_MESSAGE);
}
Program: 52062
Project: 52062
Buggy source:
protected void validate(){
  if (!newInstanceButton.getSelection() && serverNameCombo.getText().length() == 0) {
    wizard.setMessage(SPECIFY_TC_SERVER_INSTANCE_MESSAGE,IMessageProvider.NONE);
    setComplete(false);
    return;
  }
  if (wc == null) {
    wizard.setMessage("String_Node_Str",IMessageProvider.ERROR);
    setComplete(false);
    return;
  }
  IStatus status=doValidate();
  if (status == null || status.isOK()) {
    wizard.setMessage(null,IMessageProvider.NONE);
    setComplete(true);
  }
 else   if (status.getSeverity() == IStatus.INFO) {
    wizard.setMessage(status.getMessage(),IMessageProvider.NONE);
    setComplete(false);
  }
 else   if (status.getSeverity() == IStatus.WARNING) {
    wizard.setMessage(status.getMessage(),IMessageProvider.WARNING);
    setComplete(false);
  }
 else {
    wizard.setMessage(status.getMessage(),IMessageProvider.ERROR);
    setComplete(false);
  }
  updateDescription(status);
  wizard.update();
}

Fixed version (ground truth):
protected void validate(){
  if (!newInstanceButton.getSelection() && serverNameCombo.getText().length() == 0) {
    wizard.setMessage(SPECIFY_TC_SERVER_INSTANCE_MESSAGE,IMessageProvider.NONE);
    setComplete(false);
    return;
  }
  if (wc == null) {
    wizard.setMessage("String_Node_Str",IMessageProvider.ERROR);
    setComplete(false);
    return;
  }
  IStatus status=doValidate();
  if (status == null || status.isOK()) {
    wizard.setMessage(null,IMessageProvider.NONE);
    setComplete(true);
  }
 else   if (status.getSeverity() == IStatus.INFO) {
    wizard.setMessage(status.getMessage(),IMessageProvider.NONE);
    setComplete(false);
  }
 else   if (status.getSeverity() == IStatus.WARNING) {
    wizard.setMessage(status.getMessage(),IMessageProvider.WARNING);
    setComplete(true);
  }
 else {
    wizard.setMessage(status.getMessage(),IMessageProvider.ERROR);
    setComplete(false);
  }
  updateDescription(status);
  wizard.update();
}
Program: 52063
Project: 52063
Buggy source:
/** 
 * Initialize the fields in this editor.
 */
protected void initialize(){
  if (serverNameLabel == null) {
    return;
  }
  if (serverInstance.isAsfLayout()) {
    infoLabel.setText("String_Node_Str");
    serverNameLabel.setText("String_Node_Str");
  }
 else {
    String serverName=serverInstance.getServerName();
    infoLabel.setText("String_Node_Str");
    serverNameLabel.setText(serverName + "String_Node_Str" + serverInstance.getLayout().toString()+ "String_Node_Str");
  }
}

Fixed version (ground truth):
/** 
 * Initialize the fields in this editor.
 */
protected void initialize(){
  if (serverNameLabel == null) {
    return;
  }
  if (serverInstance.isAsfLayout()) {
    infoLabel.setText("String_Node_Str");
    serverNameLabel.setText("String_Node_Str");
  }
 else {
    String serverName=serverInstance.getServerName();
    infoLabel.setText("String_Node_Str");
    serverNameLabel.setText(serverName + "String_Node_Str" + serverInstance.getLayout().toString()+ "String_Node_Str");
  }
  addChangeListeners();
}
Program: 52066
Project: 52066
Buggy source:
/** 
 * send valid login email id and password to web server
 */
@Test public final void testLoginCredantial(){
  JSONObject jObjMain=new JSONObject();
  JSONObject jObj=new JSONObject();
  try {
    PhrescoLogger.info(TAG + "String_Node_Str");
    jObj.put("String_Node_Str","String_Node_Str");
    jObj.put("String_Node_Str","String_Node_Str");
    jObjMain.put("String_Node_Str",jObj);
    JSONObject responseJSON=null;
    responseJSON=JSONHelper.postJSONObjectToURL(Constants.getWebContextURL() + Constants.getRestAPI() + Constants.LOGIN_POST_URL,jObjMain.toString());
    assertNotNull("String_Node_Str",responseJSON.length() > 0);
    PhrescoLogger.info(TAG + "String_Node_Str");
  }
 catch (  IOException ex) {
    PhrescoLogger.info(TAG + "String_Node_Str" + ex.toString());
    PhrescoLogger.warning(ex);
  }
catch (  JSONException ex) {
    PhrescoLogger.info(TAG + "String_Node_Str" + ex.toString());
    PhrescoLogger.warning(ex);
  }
}

Fixed version (ground truth):
/** 
 * send valid login email id and password to web server
 */
@Test public final void testLoginCredantial() throws Exception {
  JSONObject jObjMain=new JSONObject();
  JSONObject jObj=new JSONObject();
  try {
    PhrescoLogger.info(TAG + "String_Node_Str");
    jObj.put("String_Node_Str","String_Node_Str");
    jObj.put("String_Node_Str","String_Node_Str");
    jObjMain.put("String_Node_Str",jObj);
    JSONObject responseJSON=null;
    responseJSON=JSONHelper.postJSONObjectToURL(Constants.getWebContextURL() + Constants.getRestAPI() + Constants.LOGIN_POST_URL,jObjMain.toString());
    assertNotNull("String_Node_Str",responseJSON.length() > 0);
    PhrescoLogger.info(TAG + "String_Node_Str");
  }
 catch (  IOException ex) {
    PhrescoLogger.info(TAG + "String_Node_Str" + ex.toString());
    PhrescoLogger.warning(ex);
  }
catch (  JSONException ex) {
    PhrescoLogger.info(TAG + "String_Node_Str" + ex.toString());
    PhrescoLogger.warning(ex);
  }
}