Program: 108768
Project: 108768
Buggy source:
/** 
 * Reads in preview data This goes through up to   {@link ImportData#previewDataMaxLines} lineswithin the appropriate file and reads them in. It uses {@link DataSourceImportAdapter} in combination with{@link CSVFileConfiguration} to actually read in the data.
 */
private void readPreview() throws IOException {
  final String location=comboLocation.getText();
  final char separator=separators[selection];
  final boolean containsHeader=btnContainsHeader.getSelection();
  final CSVDataInput in=new CSVDataInput(location,separator);
  final Iterator<String[]> it=in.iterator();
  final String[] firstLine;
  if (it.hasNext()) {
    firstLine=it.next();
  }
 else {
    throw new IOException("String_Node_Str");
  }
  wizardColumns=new ArrayList<WizardColumn>();
  List<Column> columns=new ArrayList<Column>();
  for (int i=0; i < firstLine.length; i++) {
    Column column=new Column(i,DataType.STRING);
    WizardColumn wizardColumn=new WizardColumn(column);
    wizardColumns.add(wizardColumn);
    columns.add(column);
  }
  CSVFileConfiguration config=new CSVFileConfiguration(location,separator,containsHeader);
  for (  Column c : columns) {
    config.addColumn(c);
  }
  DataSourceImportAdapter importAdapter=DataSourceImportAdapter.create(config);
  int count=0;
  while (importAdapter.hasNext() && (count <= ImportData.previewDataMaxLines)) {
    previewData.add(importAdapter.next());
    count++;
  }
  in.close();
  previewData.remove(0);
  if (previewData.size() == 0) {
    throw new IOException("String_Node_Str");
  }
  tablePreview.setRedraw(false);
  while (tablePreview.getColumnCount() > 0) {
    tablePreview.getColumns()[0].dispose();
  }
  for (  WizardColumn column : wizardColumns) {
    TableViewerColumn tableViewerColumn=new TableViewerColumn(tableViewerPreview,SWT.NONE);
    tableViewerColumn.setLabelProvider(new CSVColumnLabelProvider(column.getColumn().getIndex()));
    TableColumn tableColumn=tableViewerColumn.getColumn();
    tableColumn.setWidth(100);
    if (btnContainsHeader.getSelection()) {
      tableColumn.setText(column.getColumn().getName());
      tableColumn.setToolTipText("String_Node_Str" + column.getColumn().getIndex());
    }
    ColumnViewerToolTipSupport.enableFor(tableViewerPreview,ToolTip.NO_RECREATE);
  }
  tableViewerPreview.setInput(previewData);
  tablePreview.setHeaderVisible(btnContainsHeader.getSelection());
  tablePreview.setVisible(true);
  tablePreview.layout();
  tablePreview.setRedraw(true);
}

Fixed version (ground truth):
/** 
 * Reads in preview data This goes through up to   {@link ImportData#previewDataMaxLines} lineswithin the appropriate file and reads them in. It uses {@link DataSourceImportAdapter} in combination with{@link CSVFileConfiguration} to actually read in the data.
 */
private void readPreview() throws IOException {
  previewData.clear();
  final String location=comboLocation.getText();
  final char separator=separators[selection];
  final boolean containsHeader=btnContainsHeader.getSelection();
  final CSVDataInput in=new CSVDataInput(location,separator);
  final Iterator<String[]> it=in.iterator();
  final String[] firstLine;
  if (it.hasNext()) {
    firstLine=it.next();
  }
 else {
    throw new IOException("String_Node_Str");
  }
  wizardColumns=new ArrayList<WizardColumn>();
  List<Column> columns=new ArrayList<Column>();
  for (int i=0; i < firstLine.length; i++) {
    Column column=new Column(i,DataType.STRING);
    WizardColumn wizardColumn=new WizardColumn(column);
    wizardColumns.add(wizardColumn);
    columns.add(column);
  }
  CSVFileConfiguration config=new CSVFileConfiguration(location,separator,containsHeader);
  for (  Column c : columns) {
    config.addColumn(c);
  }
  DataSourceImportAdapter importAdapter=DataSourceImportAdapter.create(config);
  int count=0;
  while (importAdapter.hasNext() && (count <= ImportData.previewDataMaxLines)) {
    previewData.add(importAdapter.next());
    count++;
  }
  in.close();
  previewData.remove(0);
  if (previewData.size() == 0) {
    throw new IOException("String_Node_Str");
  }
  tablePreview.setRedraw(false);
  while (tablePreview.getColumnCount() > 0) {
    tablePreview.getColumns()[0].dispose();
  }
  for (  WizardColumn column : wizardColumns) {
    TableViewerColumn tableViewerColumn=new TableViewerColumn(tableViewerPreview,SWT.NONE);
    tableViewerColumn.setLabelProvider(new CSVColumnLabelProvider(column.getColumn().getIndex()));
    TableColumn tableColumn=tableViewerColumn.getColumn();
    tableColumn.setWidth(100);
    if (btnContainsHeader.getSelection()) {
      tableColumn.setText(column.getColumn().getName());
      tableColumn.setToolTipText("String_Node_Str" + column.getColumn().getIndex());
    }
    ColumnViewerToolTipSupport.enableFor(tableViewerPreview,ToolTip.NO_RECREATE);
  }
  tableViewerPreview.setInput(previewData);
  tablePreview.setHeaderVisible(btnContainsHeader.getSelection());
  tablePreview.setVisible(true);
  tablePreview.layout();
  tablePreview.setRedraw(true);
}