Program: 136448
Project: 136448
Buggy source:
/** 
 * DOC bZhou Comment method "addListeners".
 */
private void addListeners(){
  SelectionListener modeSwitchListener=new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      setDirState(isDirState());
      setArchState(!isDirState());
    }
  }
;
  dirBTN.addSelectionListener(modeSwitchListener);
  archBTN.addSelectionListener(modeSwitchListener);
  ModifyListener populateListener=new ModifyListener(){
    public void modifyText(    ModifyEvent e){
      updateBasePath();
    }
  }
;
  dirTxt.addModifyListener(populateListener);
  archTxt.addModifyListener(populateListener);
  browseDirBTN.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      String result=openDirectoryDialog();
      if (result != null) {
        dirTxt.setText(result);
      }
    }
    private String openDirectoryDialog(){
      DirectoryDialog dialog=new DirectoryDialog(Display.getDefault().getActiveShell());
      if (dirTxt.getText() != null) {
        dialog.setFilterPath(dirTxt.getText());
      }
      return dialog.open();
    }
  }
);
  browseArchBTN.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      String result=openFileDialog();
      if (result != null) {
        IPath path=new Path(result);
        if (StringUtils.isBlank(path.getFileExtension())) {
          path=path.addFileExtension("String_Node_Str");
        }
        archTxt.setText(path.toOSString());
      }
    }
    private String openFileDialog(){
      FileDialog dialog=new FileDialog(Display.getDefault().getActiveShell());
      dialog.setFilterExtensions(FILE_EXPORT_MASK);
      if (archTxt.getText() != null) {
        dialog.setFileName(archTxt.getText());
      }
      return dialog.open();
    }
  }
);
  repositoryTree.getTree().addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      TreeItem item=(TreeItem)e.item;
      ItemRecord record=(ItemRecord)item.getData();
      if (record.getFile().isFile()) {
        boolean checked=item.getChecked();
        if (checked) {
          for (          File file : record.getDependencySet()) {
            if (!DqFileUtils.isLocalProjectFile(file)) {
              continue;
            }
            ItemRecord findRecord=ItemRecord.findRecord(file);
            if (findRecord != null) {
              repositoryTree.setChecked(findRecord,checked);
            }
 else {
              log.error("String_Node_Str" + file.getAbsolutePath());
            }
          }
        }
 else {
          ModelElement element=record.getElement();
          List<ModelElement> dependencyClients;
          if (element != null) {
            dependencyClients=EObjectHelper.getDependencyClients(element);
          }
 else {
            Property property=record.getProperty();
            dependencyClients=ImportAndExportUtils.getContextClientDepend(property.getId());
          }
          if (!dependencyClients.isEmpty()) {
            ImportAndExportUtils.iterateUncheckClientDependency(dependencyClients,repositoryTree);
          }
        }
      }
      repositoryTree.refresh();
      checkForErrors();
    }
  }
);
}

Fixed version (ground truth):
/** 
 * DOC bZhou Comment method "addListeners".
 */
private void addListeners(){
  SelectionListener modeSwitchListener=new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      setDirState(isDirState());
      setArchState(!isDirState());
    }
  }
;
  dirBTN.addSelectionListener(modeSwitchListener);
  archBTN.addSelectionListener(modeSwitchListener);
  ModifyListener populateListener=new ModifyListener(){
    public void modifyText(    ModifyEvent e){
      updateBasePath();
    }
  }
;
  dirTxt.addModifyListener(populateListener);
  archTxt.addModifyListener(populateListener);
  browseDirBTN.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      String result=openDirectoryDialog();
      if (result != null) {
        dirTxt.setText(result);
      }
    }
    private String openDirectoryDialog(){
      DirectoryDialog dialog=new DirectoryDialog(Display.getDefault().getActiveShell());
      if (dirTxt.getText() != null) {
        dialog.setFilterPath(dirTxt.getText());
      }
      return dialog.open();
    }
  }
);
  browseArchBTN.addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      String result=openFileDialog();
      if (result != null) {
        IPath path=new Path(result);
        if (StringUtils.isBlank(path.getFileExtension())) {
          path=path.addFileExtension("String_Node_Str");
        }
        archTxt.setText(path.toOSString());
      }
    }
    private String openFileDialog(){
      FileDialog dialog=new FileDialog(Display.getDefault().getActiveShell());
      dialog.setFilterExtensions(FILE_EXPORT_MASK);
      if (archTxt.getText() != null) {
        dialog.setFileName(archTxt.getText());
      }
      return dialog.open();
    }
  }
);
  repositoryTree.getTree().addSelectionListener(new SelectionAdapter(){
    @Override public void widgetSelected(    SelectionEvent e){
      TreeItem item=(TreeItem)e.item;
      ItemRecord record=(ItemRecord)item.getData();
      if (record.getFile().isFile()) {
        boolean checked=item.getChecked();
        if (checked) {
          for (          File file : record.getDependencySet()) {
            if (!DqFileUtils.isLocalProjectFile(file)) {
              continue;
            }
            ItemRecord findRecord=ItemRecord.findRecord(file);
            if (findRecord != null) {
              repositoryTree.setChecked(findRecord,checked);
            }
 else {
              log.error("String_Node_Str" + file.getAbsolutePath());
            }
          }
        }
 else {
          ModelElement element=record.getElement();
          List<ModelElement> dependencyClients;
          if (element != null) {
            dependencyClients=EObjectHelper.getDependencyClients(element);
          }
 else {
            Property property=record.getProperty();
            dependencyClients=ImportAndExportUtils.getContextClientDepend(property.getId());
          }
          if (!dependencyClients.isEmpty()) {
            ImportAndExportUtils.iterateUncheckClientDependency(dependencyClients,repositoryTree);
          }
        }
      }
      checkForErrors();
    }
  }
);
}