Program: 140541
Project: 140541
Buggy source:
/** 
 * DOC qzhang Comment method "createIndicatorParameters".
 * @param indicatorItem
 * @param parameters
 */
private void createIndicatorParameters(TreeItem indicatorItem,IndicatorUnit indicatorUnit){
  TreeItem[] items=indicatorItem.getItems();
  if (indicatorItem != null && !indicatorItem.isDisposed()) {
    for (    TreeItem treeItem : items) {
      if (DATA_PARAM.equals(treeItem.getData(DATA_PARAM))) {
        treeItem.dispose();
      }
    }
  }
  IndicatorParameters parameters=indicatorUnit.getIndicator().getParameters();
  if (parameters == null) {
    return;
  }
  TreeItem iParamItem=new TreeItem(indicatorItem,SWT.NONE);
  iParamItem.setText(0,"String_Node_Str" + parameters.getTopN());
  iParamItem.setData(DATA_PARAM,DATA_PARAM);
  iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  TextParameters tParameter=parameters.getTextParameter();
  if (tParameter != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str");
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    TreeItem subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + tParameter.isUseBlank());
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + tParameter.isIgnoreCase());
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + tParameter.isUseNulls());
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
  DateParameters dParameters=parameters.getDateParameters();
  if (dParameters != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str");
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    TreeItem subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + dParameters.getDateAggregationType().getName() + "String_Node_Str");
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
  iParamItem=new TreeItem(indicatorItem,SWT.NONE);
  iParamItem.setText(0,"String_Node_Str" + (parameters.getDataValidDomain() != null));
  iParamItem.setData(DATA_PARAM,DATA_PARAM);
  iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  iParamItem=new TreeItem(indicatorItem,SWT.NONE);
  iParamItem.setText(0,"String_Node_Str" + (parameters.getIndicatorValidDomain() != null));
  iParamItem.setData(DATA_PARAM,DATA_PARAM);
  iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  iParamItem=new TreeItem(indicatorItem,SWT.NONE);
  iParamItem.setText(0,"String_Node_Str" + (parameters.getBins() != null));
  iParamItem.setData(DATA_PARAM,DATA_PARAM);
  iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
}

Fixed version (ground truth):
/** 
 * DOC qzhang Comment method "createIndicatorParameters".
 * @param indicatorItem
 * @param parameters
 */
private void createIndicatorParameters(TreeItem indicatorItem,IndicatorUnit indicatorUnit){
  TreeItem[] items=indicatorItem.getItems();
  if (indicatorItem != null && !indicatorItem.isDisposed()) {
    for (    TreeItem treeItem : items) {
      if (DATA_PARAM.equals(treeItem.getData(DATA_PARAM))) {
        treeItem.dispose();
      }
    }
  }
  IndicatorParameters parameters=indicatorUnit.getIndicator().getParameters();
  if (parameters == null) {
    return;
  }
  TreeItem iParamItem=new TreeItem(indicatorItem,SWT.NONE);
  iParamItem.setText(0,"String_Node_Str" + parameters.getTopN());
  iParamItem.setData(DATA_PARAM,DATA_PARAM);
  iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  TextParameters tParameter=parameters.getTextParameter();
  if (tParameter != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str");
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    TreeItem subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + tParameter.isUseBlank());
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + tParameter.isIgnoreCase());
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + tParameter.isUseNulls());
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
  DateParameters dParameters=parameters.getDateParameters();
  if (dParameters != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str");
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
    TreeItem subParamItem=new TreeItem(iParamItem,SWT.NONE);
    subParamItem.setText("String_Node_Str" + dParameters.getDateAggregationType().getName() + "String_Node_Str");
    subParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
  Domain dataValidDomain=parameters.getDataValidDomain();
  if (dataValidDomain != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str" + (dataValidDomain != null));
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
  Domain indicatorValidDomain=parameters.getIndicatorValidDomain();
  if (indicatorValidDomain != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str" + (indicatorValidDomain != null));
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
  Domain bins=parameters.getBins();
  if (bins != null) {
    iParamItem=new TreeItem(indicatorItem,SWT.NONE);
    iParamItem.setText(0,"String_Node_Str" + (bins != null));
    iParamItem.setData(DATA_PARAM,DATA_PARAM);
    iParamItem.setImage(0,ImageLib.getImage(ImageLib.OPTION));
  }
}