Program: 102122
Project: 102122
Buggy source:
private Composite createIndexesPanel(Composite parent){
  Composite thePanel=WidgetFactory.createPanel(parent,SWT.NONE,1,2);
  GridLayoutFactory.fillDefaults().margins(10,10).applyTo(thePanel);
  GridDataFactory.fillDefaults().grab(true,true).applyTo(thePanel);
  Composite buttonPanel=new Composite(thePanel,SWT.NONE);
  GridLayoutFactory.fillDefaults().numColumns(3).applyTo(buttonPanel);
  GridDataFactory.fillDefaults().grab(true,false).applyTo(buttonPanel);
  this.addIndexButton=new Button(buttonPanel,SWT.PUSH);
  this.addIndexButton.setText(UILabelUtil.getLabel(UiLabelConstants.LABEL_IDS.ADD));
  GridDataFactory.fillDefaults().applyTo(this.addIndexButton);
  this.addIndexButton.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      RelationalIndex newIndex=new RelationalIndex();
      EditIndexDialog dialog=new EditIndexDialog(getShell(),getRelationalReference(),newIndex,false);
      int result=dialog.open();
      if (result == Window.OK) {
        getRelationalReference().addIndex(newIndex);
      }
      handleInfoChanged();
    }
  }
);
  this.editIndexButton=new Button(buttonPanel,SWT.PUSH);
  this.editIndexButton.setText(UILabelUtil.getLabel(UiLabelConstants.LABEL_IDS.EDIT_ELIPSIS));
  GridDataFactory.fillDefaults().applyTo(this.editIndexButton);
  this.editIndexButton.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      RelationalIndex index=null;
      IStructuredSelection selection=(IStructuredSelection)indexesViewer.getSelection();
      for (      Object obj : selection.toArray()) {
        if (obj instanceof RelationalIndex) {
          index=(RelationalIndex)obj;
          break;
        }
      }
      if (index != null) {
        EditIndexDialog dialog=new EditIndexDialog(getShell(),getRelationalReference(),index,true);
        int result=dialog.open();
        if (result == Window.OK) {
        }
        handleInfoChanged();
      }
    }
  }
);
  this.deleteIndexButton=new Button(buttonPanel,SWT.PUSH);
  this.deleteIndexButton.setText(UILabelUtil.getLabel(UiLabelConstants.LABEL_IDS.DELETE));
  GridDataFactory.fillDefaults().applyTo(this.deleteIndexButton);
  this.deleteIndexButton.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      RelationalIndex index=null;
      IStructuredSelection selection=(IStructuredSelection)fkViewer.getSelection();
      for (      Object obj : selection.toArray()) {
        if (obj instanceof RelationalIndex) {
          index=(RelationalIndex)obj;
          break;
        }
      }
      if (index != null) {
        getRelationalReference().removeIndex(index);
        deleteIndexButton.setEnabled(false);
        handleInfoChanged();
      }
    }
  }
);
  Table columnTable=new Table(thePanel,SWT.SINGLE | SWT.H_SCROLL | SWT.V_SCROLL| SWT.BORDER);
  columnTable.setHeaderVisible(true);
  columnTable.setLinesVisible(true);
  columnTable.setLayout(new TableLayout());
  this.indexesViewer=new TableViewer(columnTable);
  GridDataFactory.fillDefaults().grab(true,false).hint(SWT.DEFAULT,200).applyTo(this.indexesViewer.getControl());
  TableViewerColumn column=new TableViewerColumn(this.indexesViewer,SWT.LEFT);
  column.getColumn().setText(Messages.indexLabel);
  column.setLabelProvider(new IndexDataLabelProvider(0));
  column.getColumn().pack();
  if (getRelationalReference() != null && getRelationalReference().getIndexes() != null) {
    for (    RelationalIndex row : this.getRelationalReference().getIndexes()) {
      this.indexesViewer.add(row);
    }
  }
  return thePanel;
}

Fixed version (ground truth):
private Composite createIndexesPanel(Composite parent){
  Composite thePanel=WidgetFactory.createPanel(parent,SWT.NONE,1,2);
  GridLayoutFactory.fillDefaults().margins(10,10).applyTo(thePanel);
  GridDataFactory.fillDefaults().grab(true,true).applyTo(thePanel);
  Composite buttonPanel=new Composite(thePanel,SWT.NONE);
  GridLayoutFactory.fillDefaults().numColumns(3).applyTo(buttonPanel);
  GridDataFactory.fillDefaults().grab(true,false).applyTo(buttonPanel);
  this.addIndexButton=new Button(buttonPanel,SWT.PUSH);
  this.addIndexButton.setText(UILabelUtil.getLabel(UiLabelConstants.LABEL_IDS.ADD));
  GridDataFactory.fillDefaults().applyTo(this.addIndexButton);
  this.addIndexButton.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      RelationalIndex newIndex=new RelationalIndex();
      EditIndexDialog dialog=new EditIndexDialog(getShell(),getRelationalReference(),newIndex,false);
      int result=dialog.open();
      if (result == Window.OK) {
        getRelationalReference().addIndex(newIndex);
      }
      handleInfoChanged();
    }
  }
);
  this.editIndexButton=new Button(buttonPanel,SWT.PUSH);
  this.editIndexButton.setText(UILabelUtil.getLabel(UiLabelConstants.LABEL_IDS.EDIT_ELIPSIS));
  GridDataFactory.fillDefaults().applyTo(this.editIndexButton);
  this.editIndexButton.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      RelationalIndex index=null;
      IStructuredSelection selection=(IStructuredSelection)indexesViewer.getSelection();
      for (      Object obj : selection.toArray()) {
        if (obj instanceof RelationalIndex) {
          index=(RelationalIndex)obj;
          break;
        }
      }
      if (index != null) {
        EditIndexDialog dialog=new EditIndexDialog(getShell(),getRelationalReference(),index,true);
        int result=dialog.open();
        if (result == Window.OK) {
        }
        handleInfoChanged();
      }
    }
  }
);
  this.deleteIndexButton=new Button(buttonPanel,SWT.PUSH);
  this.deleteIndexButton.setText(UILabelUtil.getLabel(UiLabelConstants.LABEL_IDS.DELETE));
  GridDataFactory.fillDefaults().applyTo(this.deleteIndexButton);
  this.deleteIndexButton.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      RelationalIndex index=null;
      IStructuredSelection selection=(IStructuredSelection)fkViewer.getSelection();
      for (      Object obj : selection.toArray()) {
        if (obj instanceof RelationalIndex) {
          index=(RelationalIndex)obj;
          break;
        }
      }
      if (index != null) {
        getRelationalReference().removeIndex(index);
        deleteIndexButton.setEnabled(false);
        handleInfoChanged();
      }
    }
  }
);
  Table columnTable=new Table(thePanel,SWT.SINGLE | SWT.H_SCROLL | SWT.V_SCROLL| SWT.BORDER);
  columnTable.setHeaderVisible(true);
  columnTable.setLinesVisible(true);
  columnTable.setLayout(new TableLayout());
  this.indexesViewer=new TableViewer(columnTable);
  GridDataFactory.fillDefaults().grab(true,true).hint(SWT.DEFAULT,200).applyTo(this.indexesViewer.getControl());
  TableViewerColumn column=new TableViewerColumn(this.indexesViewer,SWT.LEFT);
  column.getColumn().setText(Messages.indexLabel);
  column.setLabelProvider(new IndexDataLabelProvider(0));
  column.getColumn().pack();
  if (getRelationalReference() != null && getRelationalReference().getIndexes() != null) {
    for (    RelationalIndex row : this.getRelationalReference().getIndexes()) {
      this.indexesViewer.add(row);
    }
  }
  return thePanel;
}