Program: 108207
Project: 108207
Buggy source:
@Override protected Control createDialogArea(final Composite parent){
  parent.setLayout(SWTUtil.createGridLayout(1));
  final Table table=new Table(parent,SWT.BORDER | SWT.SINGLE | SWT.V_SCROLL| SWT.FULL_SELECTION);
  table.setHeaderVisible(true);
  final GridData d=SWTUtil.createFillGridData();
  d.heightHint=100;
  table.setLayoutData(d);
  TableColumn column1=new TableColumn(table,SWT.NONE);
  column1.setText("String_Node_Str");
  TableColumn column2=new TableColumn(table,SWT.NONE);
  column2.setText(Resources.getMessage("String_Node_Str"));
  TableColumn column3=new TableColumn(table,SWT.NONE);
  column3.setText(Resources.getMessage("String_Node_Str"));
  this.symbolL=controller.getResources().getImage("String_Node_Str");
  this.symbolT=controller.getResources().getImage("String_Node_Str");
  this.symbolK=controller.getResources().getImage("String_Node_Str");
  this.symbolD=controller.getResources().getImage("String_Node_Str");
  this.symbolR=controller.getResources().getImage("String_Node_Str");
  for (  ModelCriterion c : elements) {
    TableItem item=new TableItem(table,SWT.NONE);
    if (c instanceof ModelLDiversityCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),((ModelLDiversityCriterion)c).getAttribute()});
      item.setImage(0,symbolL);
    }
 else     if (c instanceof ModelTClosenessCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),((ModelTClosenessCriterion)c).getAttribute()});
      item.setImage(0,symbolT);
    }
 else     if (c instanceof ModelKAnonymityCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),"String_Node_Str"});
      item.setImage(0,symbolK);
    }
 else     if (c instanceof ModelDPresenceCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),"String_Node_Str"});
      item.setImage(0,symbolD);
    }
 else     if (c instanceof ModelRiskBasedCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),"String_Node_Str"});
      item.setImage(0,symbolR);
    }
  }
  table.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent arg0){
      if (table.getSelectionIndex() != -1) {
        selection=elements.get(table.getSelectionIndex());
        if (edit)         ok.setEnabled(true);
        update();
      }
 else {
        selection=null;
        if (edit)         ok.setEnabled(false);
        update();
      }
    }
  }
);
  column1.pack();
  column2.pack();
  column3.pack();
  ComponentTitledBorder border=new ComponentTitledBorder(parent,"String_Node_Str");
  border.setLayoutData(SWTUtil.createFillGridData());
  this.root=new Composite(border.getControl(),SWT.NONE);
  border.setChild(root);
  this.root.setLayout(SWTUtil.createGridLayout(1));
  if (selection != null) {
    table.setSelection(elements.indexOf(selection));
  }
 else {
    table.setSelection(0);
    selection=elements.get(0);
  }
  update();
  return parent;
}

Fixed version (ground truth):
@Override protected Control createDialogArea(final Composite parent){
  parent.setLayout(SWTUtil.createGridLayout(1));
  final DynamicTable table=new DynamicTable(parent,SWT.BORDER | SWT.SINGLE | SWT.V_SCROLL| SWT.FULL_SELECTION);
  table.setHeaderVisible(true);
  final GridData d=SWTUtil.createFillGridData();
  d.heightHint=100;
  table.setLayoutData(d);
  DynamicTableColumn column1=new DynamicTableColumn(table,SWT.NONE);
  column1.setText("String_Node_Str");
  column1.setWidth("String_Node_Str","String_Node_Str");
  DynamicTableColumn column2=new DynamicTableColumn(table,SWT.NONE);
  column2.setText(Resources.getMessage("String_Node_Str"));
  column2.setWidth("String_Node_Str","String_Node_Str");
  DynamicTableColumn column3=new DynamicTableColumn(table,SWT.NONE);
  column3.setText(Resources.getMessage("String_Node_Str"));
  column3.setWidth("String_Node_Str","String_Node_Str");
  column1.pack();
  column2.pack();
  column3.pack();
  this.symbolL=controller.getResources().getImage("String_Node_Str");
  this.symbolT=controller.getResources().getImage("String_Node_Str");
  this.symbolK=controller.getResources().getImage("String_Node_Str");
  this.symbolD=controller.getResources().getImage("String_Node_Str");
  this.symbolR=controller.getResources().getImage("String_Node_Str");
  for (  ModelCriterion c : elements) {
    TableItem item=new TableItem(table,SWT.NONE);
    if (c instanceof ModelLDiversityCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),((ModelLDiversityCriterion)c).getAttribute()});
      item.setImage(0,symbolL);
    }
 else     if (c instanceof ModelTClosenessCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),((ModelTClosenessCriterion)c).getAttribute()});
      item.setImage(0,symbolT);
    }
 else     if (c instanceof ModelKAnonymityCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),"String_Node_Str"});
      item.setImage(0,symbolK);
    }
 else     if (c instanceof ModelDPresenceCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),"String_Node_Str"});
      item.setImage(0,symbolD);
    }
 else     if (c instanceof ModelRiskBasedCriterion) {
      item.setText(new String[]{"String_Node_Str",c.getLabel(),"String_Node_Str"});
      item.setImage(0,symbolR);
    }
  }
  table.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent arg0){
      if (table.getSelectionIndex() != -1) {
        selection=elements.get(table.getSelectionIndex());
        if (edit)         ok.setEnabled(true);
        update();
      }
 else {
        selection=null;
        if (edit)         ok.setEnabled(false);
        update();
      }
    }
  }
);
  ComponentTitledBorder border=new ComponentTitledBorder(parent,"String_Node_Str");
  border.setLayoutData(SWTUtil.createFillGridData());
  this.root=new Composite(border.getControl(),SWT.NONE);
  border.setChild(root);
  this.root.setLayout(SWTUtil.createGridLayout(1));
  if (selection != null) {
    table.setSelection(elements.indexOf(selection));
  }
 else {
    table.setSelection(0);
    selection=elements.get(0);
  }
  update();
  return parent;
}