Program: 67465
Project: 67465
Buggy source:
private Button createBrowerButton(Composite parent,final Text text,final boolean needQuote,final boolean needFilter,final String[] fileExt){
  Button button=new Button(parent,SWT.PUSH);
  GridData gd=new GridData();
  if (!Platform.getOS().equals(Platform.OS_MACOSX)) {
    gd.widthHint=20;
    gd.heightHint=20;
  }
  button.setLayoutData(gd);
  button.setImage(IMAGE_OPEN_FILE);
  button.setToolTipText(TOOLTIP_BROWSE_FILE);
  button.addSelectionListener(new SelectionAdapter(){
    public void widgetSelected(    SelectionEvent e){
      String filename=null;
      if (!isIDE || getProjectFolder() == null) {
        FileDialog dialog=new FileDialog(UIUtil.getDefaultShell());
        if (needFilter) {
          dialog.setFilterExtensions(fileExt);
        }
        filename=dialog.open();
      }
 else {
        ProjectFileDialog dialog;
        if (needFilter) {
          dialog=new ProjectFileDialog(getProjectFolder(),fileExt);
        }
 else         dialog=new ProjectFileDialog(getProjectFolder());
        if (dialog.open() == Window.OK) {
          filename=dialog.getPath();
        }
      }
      try {
        if (filename != null) {
          File file=new File(filename);
          if (!(file.isFile() && file.exists())) {
            ExceptionHandler.openErrorMessageBox(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"));
            return;
          }
          filename=file.toURL().toString();
          if (needFilter && checkExtensions(fileExt,filename) == false) {
            ExceptionHandler.openErrorMessageBox(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"));
            return;
          }
          filename=URIUtil.getRelativePath(getBasePath(),filename);
          filename=new Path(filename).toString();
          if (text.getData(ExpressionButtonUtil.EXPR_BUTTON) != null) {
            text.setData(ExpressionButtonUtil.EXPR_TYPE,ExpressionType.CONSTANT);
            ((ExpressionButton)text.getData(ExpressionButtonUtil.EXPR_BUTTON)).refresh();
          }
 else {
            if (needQuote) {
              filename="String_Node_Str" + filename + "String_Node_Str";
            }
          }
          text.setText(filename);
          text.setFocus();
        }
        updateButtons();
      }
 catch (      Exception ex) {
        ExceptionHandler.handle(ex);
      }
    }
  }
);
  return button;
}

Fixed version (ground truth):
private Button createBrowerButton(Composite parent,final Text text,final boolean needQuote,final boolean needFilter,final String[] fileExt){
  Button button=new Button(parent,SWT.PUSH);
  GridData gd=new GridData();
  if (!Platform.getOS().equals(Platform.OS_MACOSX)) {
    gd.widthHint=20;
    gd.heightHint=20;
  }
  button.setLayoutData(gd);
  button.setImage(IMAGE_OPEN_FILE);
  button.setToolTipText(TOOLTIP_BROWSE_FILE);
  button.addSelectionListener(new SelectionAdapter(){
    public void widgetSelected(    SelectionEvent e){
      boolean projectMode=false;
      String filename=null;
      if (!isIDE || getProjectFolder() == null) {
        FileDialog dialog=new FileDialog(UIUtil.getDefaultShell());
        if (needFilter) {
          dialog.setFilterExtensions(fileExt);
        }
        filename=dialog.open();
      }
 else {
        projectMode=true;
        ProjectFileDialog dialog;
        if (needFilter) {
          dialog=new ProjectFileDialog(getProjectFolder(),fileExt);
        }
 else {
          dialog=new ProjectFileDialog(getProjectFolder());
        }
        if (dialog.open() == Window.OK) {
          filename=dialog.getPath();
        }
      }
      try {
        if (filename != null) {
          File file=new File(filename);
          if (!(file.isFile() && file.exists())) {
            ExceptionHandler.openErrorMessageBox(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"));
            return;
          }
          filename=file.toURL().toString();
          if (needFilter && checkExtensions(fileExt,filename) == false) {
            ExceptionHandler.openErrorMessageBox(Messages.getString("String_Node_Str"),Messages.getString("String_Node_Str"));
            return;
          }
          if (projectMode && isRelativeToProjectRoot) {
            filename=URIUtil.getRelativePath(getProjectFolder(),filename);
            if (!filename.startsWith("String_Node_Str")) {
              filename="String_Node_Str" + filename;
            }
          }
 else {
            filename=URIUtil.getRelativePath(getBasePath(),filename);
          }
          filename=new Path(filename).toString();
          if (text.getData(ExpressionButtonUtil.EXPR_BUTTON) != null) {
            text.setData(ExpressionButtonUtil.EXPR_TYPE,ExpressionType.CONSTANT);
            ((ExpressionButton)text.getData(ExpressionButtonUtil.EXPR_BUTTON)).refresh();
          }
 else {
            if (needQuote) {
              filename="String_Node_Str" + filename + "String_Node_Str";
            }
          }
          text.setText(filename);
          text.setFocus();
        }
        updateButtons();
      }
 catch (      Exception ex) {
        ExceptionHandler.handle(ex);
      }
    }
  }
);
  return button;
}