Program: 120551
Project: 120551
Buggy source:
private void createTreeViewer(Composite itemComposite){
  filteredCheckboxTree=new FilteredCheckboxTree(itemComposite,SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL| SWT.MULTI){
    @Override protected CheckboxTreeViewer doCreateTreeViewer(    Composite parent,    int style){
      RepoCommonViewerProvider provider=RepoCommonViewerProvider.CHECKBOX;
      if (baseViewId != null) {
        provider.setViewId(baseViewId);
      }
      return (CheckboxTreeViewer)provider.createViewer(parent);
    }
    @Override protected void refreshCompleted(){
      getViewer().expandToLevel(3);
      restoreCheckedElements();
    }
    @Override protected boolean isNodeCollectable(    TreeItem item){
      Object obj=item.getData();
      if (obj instanceof RepositoryNode) {
        RepositoryNode node=(RepositoryNode)obj;
        if (node.getObjectType() == ERepositoryObjectType.METADATA_CONNECTIONS) {
          return true;
        }
      }
      return false;
    }
  }
;
  filteredCheckboxTree.getViewer().addFilter(new ViewerFilter(){
    @Override public boolean select(    Viewer viewer,    Object parentElement,    Object element){
      if (element instanceof RepositoryNode) {
        return selectRepositoryNode(viewer,(RepositoryNode)element);
      }
 else {
        for (        IExtendedNodeHandler nodeHandler : RepositoryContentManager.getExtendedNodeHandler()) {
          boolean exportFilter=nodeHandler.exportFilter(viewer,parentElement,element);
          if (!exportFilter) {
            return exportFilter;
          }
        }
      }
      return true;
    }
  }
);
}

Fixed version (ground truth):
private void createTreeViewer(Composite itemComposite){
  filteredCheckboxTree=new FilteredCheckboxTree(itemComposite,SWT.BORDER | SWT.V_SCROLL | SWT.H_SCROLL| SWT.MULTI){
    @Override protected CheckboxTreeViewer doCreateTreeViewer(    Composite parent,    int style){
      RepoCommonViewerProvider provider=RepoCommonViewerProvider.CHECKBOX;
      if (baseViewId != null) {
        provider.setViewId(baseViewId);
      }
      return (CheckboxTreeViewer)provider.createViewer(parent);
    }
    @Override protected void refreshCompleted(){
      getViewer().expandToLevel(3);
      restoreCheckedElements();
    }
    @Override protected boolean isNodeCollectable(    TreeItem item){
      Object obj=item.getData();
      if (obj instanceof RepositoryNode) {
        RepositoryNode node=(RepositoryNode)obj;
        if (node.getObjectType() == ERepositoryObjectType.METADATA_CONNECTIONS) {
          return true;
        }
      }
      return false;
    }
  }
;
  filteredCheckboxTree.getViewer().addFilter(new ViewerFilter(){
    @Override public boolean select(    Viewer viewer,    Object parentElement,    Object element){
      boolean select=true;
      if (element instanceof RepositoryNode) {
        select=selectRepositoryNode(viewer,(RepositoryNode)element);
      }
      if (select) {
        for (        IExtendedNodeHandler nodeHandler : RepositoryContentManager.getExtendedNodeHandler()) {
          boolean exportFilter=nodeHandler.exportFilter(viewer,parentElement,element);
          if (!exportFilter) {
            return exportFilter;
          }
        }
      }
      return select;
    }
  }
);
}