Program: 120050
Project: 120050
Buggy source:
/** 
 * DOC hcw Comment method "createContents".
 * @param composite
 */
@Override Control createScdContents(Composite parent){
  Composite composite=new Composite(parent,SWT.NONE);
  GridLayoutFactory.swtDefaults().numColumns(2).equalWidth(true).spacing(20,10).applyTo(composite);
  GridDataFactory.fillDefaults().applyTo(composite);
  Composite filterUnusedComposite=new Composite(composite,SWT.NONE);
  GridLayoutFactory.swtDefaults().margins(0,0).spacing(0,0).applyTo(filterUnusedComposite);
  GridDataFactory.fillDefaults().span(1,2).hint(SECTION_WIDTH,SECTION_HEIGHT * 2 + 20).applyTo(filterUnusedComposite);
  ViewerFilter filter=createFilter(filterUnusedComposite);
  unusedFields=new FieldSection(filterUnusedComposite,SECTION_WIDTH - 5,SECTION_HEIGHT,scdManager,false,false);
  unusedFields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(198,195,198));
  unusedFields.setTableInput(scdManager.getUnusedFields());
  unusedFields.getTableViewer().addFilter(filter);
  unusedFields.setSortable(true);
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH - 5,SECTION_HEIGHT * 2 - 20).applyTo(unusedFields.getControl());
  addContextHelp(unusedFields.getTableViewer().getTable(),"String_Node_Str");
  type0Fields=new FieldSection(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager,false,false);
  type0Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(255,146,0));
  type0Fields.setTableInput(scdManager.getType0Table());
  addContextHelp(type0Fields.getTableViewer().getTable(),"String_Node_Str");
  type1Fields=new FieldSection(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager,false,false);
  type1Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(255,203,0));
  type1Fields.setTableInput(scdManager.getType1Table());
  addContextHelp(type1Fields.getTableViewer().getTable(),"String_Node_Str");
  sourceKeys=new FieldSection(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager,false,false);
  sourceKeys.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(156,0,255));
  sourceKeys.setTableInput(scdManager.getSourceKeys());
  addContextHelp(sourceKeys.getTableViewer().getTable(),"String_Node_Str");
  type2Fields=new Type2Section(composite,SECTION_WIDTH,SECTION_HEIGHT * 2 + 40,scdManager);
  type2Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(255,255,0));
  GridDataFactory.swtDefaults().span(1,2).hint(SECTION_WIDTH,SECTION_HEIGHT * 2 + 40).applyTo(type2Fields.getControl());
  type2Fields.setTableInput(scdManager.getType2Table());
  if (scdManager.getVersionData() != null) {
    type2Fields.setVersionInput(scdManager.getVersionData());
  }
 else {
    type2Fields.setVersionInput(new Versioning());
  }
  addContextHelp(type2Fields.getTableViewer().getTable(),"String_Node_Str");
  surrogateKeys=new SurrogateSection(composite,SECTION_WIDTH,SECTION_HEIGHT + 30,scdManager);
  surrogateKeys.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(214,40,255));
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH,SECTION_HEIGHT + 30).applyTo(surrogateKeys.getControl());
  surrogateKeys.setTableInput(scdManager.getSurrogateKeys());
  surrogateKeys.addContextHelp(this);
  Label placeHolder=new Label(composite,SWT.NONE);
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH,SECTION_HEIGHT).applyTo(placeHolder);
  type3Fields=new Type3Section(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager);
  type3Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(24,182,255));
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH,SECTION_HEIGHT + 20).applyTo(type3Fields.getControl());
  type3Fields.setTableInput(scdManager.getType3Table());
  addContextHelp(type3Fields.getTable(),"String_Node_Str");
  scdManager.setUnusedFieldsSource(unusedFields);
  ScdSection[] sections={surrogateKeys,sourceKeys,type0Fields,type1Fields,type2Fields,type3Fields};
  for (  ScdSection scd : sections) {
    scdManager.addUnusedFieldsTarget(scd);
  }
  return composite;
}

Fixed version (ground truth):
/** 
 * DOC hcw Comment method "createContents".
 * @param composite
 */
@Override Control createScdContents(Composite parent){
  Composite composite=new Composite(parent,SWT.NONE);
  GridLayoutFactory.swtDefaults().numColumns(2).equalWidth(true).spacing(20,10).applyTo(composite);
  GridDataFactory.fillDefaults().applyTo(composite);
  Composite filterUnusedComposite=new Composite(composite,SWT.NONE);
  GridLayoutFactory.swtDefaults().margins(0,0).spacing(0,0).applyTo(filterUnusedComposite);
  GridDataFactory.fillDefaults().span(1,2).hint(SECTION_WIDTH,SECTION_HEIGHT * 2 + 20).applyTo(filterUnusedComposite);
  ViewerFilter filter=createFilter(filterUnusedComposite);
  unusedFields=new FieldSection(filterUnusedComposite,SECTION_WIDTH - 5,SECTION_HEIGHT,scdManager,false,false);
  unusedFields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(198,195,198));
  unusedFields.setTableInput(scdManager.getUnusedFields());
  unusedFields.getTableViewer().addFilter(filter);
  unusedFields.setSortable(true);
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH - 5,SECTION_HEIGHT * 2 - 20).applyTo(unusedFields.getControl());
  addContextHelp(unusedFields.getTableViewer().getTable(),"String_Node_Str");
  type0Fields=new FieldSection(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager,false,false);
  type0Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(255,146,0));
  type0Fields.setTableInput(scdManager.getType0Table());
  addContextHelp(type0Fields.getTableViewer().getTable(),"String_Node_Str");
  type1Fields=new FieldSection(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager,false,false,ScdParameterConstants.DROP_COPY_TYPE1FIELDS);
  type1Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(255,203,0));
  type1Fields.setTableInput(scdManager.getType1Table());
  addContextHelp(type1Fields.getTableViewer().getTable(),"String_Node_Str");
  sourceKeys=new FieldSection(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager,false,false,ScdParameterConstants.DROP_COPY_SOURCEKEYS);
  sourceKeys.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(156,0,255));
  sourceKeys.setTableInput(scdManager.getSourceKeys());
  addContextHelp(sourceKeys.getTableViewer().getTable(),"String_Node_Str");
  type2Fields=new Type2Section(composite,SECTION_WIDTH,SECTION_HEIGHT * 2 + 40,scdManager,ScdParameterConstants.DROP_COPY_TYPE2FIELDS);
  type2Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(255,255,0));
  GridDataFactory.swtDefaults().span(1,2).hint(SECTION_WIDTH,SECTION_HEIGHT * 2 + 40).applyTo(type2Fields.getControl());
  type2Fields.setTableInput(scdManager.getType2Table());
  if (scdManager.getVersionData() != null) {
    type2Fields.setVersionInput(scdManager.getVersionData());
  }
 else {
    type2Fields.setVersionInput(new Versioning());
  }
  addContextHelp(type2Fields.getTableViewer().getTable(),"String_Node_Str");
  surrogateKeys=new SurrogateSection(composite,SECTION_WIDTH,SECTION_HEIGHT + 30,scdManager);
  surrogateKeys.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(214,40,255));
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH,SECTION_HEIGHT + 30).applyTo(surrogateKeys.getControl());
  surrogateKeys.setTableInput(scdManager.getSurrogateKeys());
  surrogateKeys.addContextHelp(this);
  Label placeHolder=new Label(composite,SWT.NONE);
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH,SECTION_HEIGHT).applyTo(placeHolder);
  type3Fields=new Type3Section(composite,SECTION_WIDTH,SECTION_HEIGHT,scdManager);
  type3Fields.setTitle(Messages.getString("String_Node_Str"),SWTResourceManager.getColor(24,182,255));
  GridDataFactory.swtDefaults().hint(SECTION_WIDTH,SECTION_HEIGHT + 20).applyTo(type3Fields.getControl());
  type3Fields.setTableInput(scdManager.getType3Table());
  addContextHelp(type3Fields.getTable(),"String_Node_Str");
  scdManager.setUnusedFieldsSource(unusedFields);
  ScdSection[] sections={surrogateKeys,sourceKeys,type0Fields,type1Fields,type2Fields,type3Fields};
  for (  ScdSection scd : sections) {
    scdManager.addUnusedFieldsTarget(scd);
  }
  return composite;
}