Program: 79090
Project: 79090
Buggy source:
private void addFetchColumnListener(){
  availableDbObjectsTree.addListener(SWT.Expand,new Listener(){
    public void handleEvent(    Event event){
      TreeItem item=(TreeItem)event.item;
      if (item == null)       return;
      if (isSchemaNode(item) || (item == rootNode)) {
        return;
      }
      String tableName=Utility.getTreeItemsName(item);
      String catalogName=metaDataProvider.getCatalog();
      String schemaName=null;
      String schemaSeparator="String_Node_Str";
      if (metaDataProvider.isSchemaSupported()) {
        int index=-1;
        if ((index=tableName.lastIndexOf(schemaSeparator)) != -1) {
          schemaName=tableName.substring(0,index);
          tableName=tableName.substring(index + 1);
        }
      }
      if (item.getData() instanceof DbObject) {
        DbObject obj=(DbObject)item.getData();
        if (obj.getType() == DbObject.TABLE_TYPE || obj.getType() == DbObject.VIEW_TYPE) {
          ArrayList columnList=metaDataProvider.getColumns(catalogName,schemaName,tableName,null);
          TreeItem[] items=item.getItems();
          if (items != null) {
            for (int i=0; i < items.length; i++) {
              items[i].dispose();
            }
          }
          Utility.createTreeItems(item,columnList,SWT.NONE,columnImage);
        }
 else         if (obj.getType() == DbObject.PROCEDURE_TYPE) {
          ArrayList procedureList=metaDataProvider.getAllProcedure(catalogName,schemaName,getTailoredSearchText(searchTxt.getText()));
          TreeItem[] items=item.getItems();
          if (items != null) {
            for (int i=0; i < items.length; i++) {
              items[i].dispose();
            }
          }
          Utility.createTreeItems(item,procedureList,SWT.NONE,columnImage);
        }
      }
 else       if (item.getData() instanceof Procedure) {
        Procedure obj=(Procedure)item.getData();
{
          ArrayList columnList=metaDataProvider.getProcedureColumns(obj.getCatalog(),schemaName,tableName,null);
          TreeItem[] items=item.getItems();
          if (items != null) {
            for (int i=0; i < items.length; i++) {
              items[i].dispose();
            }
          }
          Utility.createTreeItems(item,columnList,SWT.NONE,columnImage);
        }
      }
    }
  }
);
}

Fixed version (ground truth):
private void addFetchColumnListener(){
  availableDbObjectsTree.addListener(SWT.Expand,new Listener(){
    public void handleEvent(    Event event){
      TreeItem item=(TreeItem)event.item;
      if (item == null)       return;
      if (isSchemaNode(item) || (item == rootNode)) {
        return;
      }
      String tableName=Utility.getTreeItemsName(item);
      String catalogName=metaDataProvider.getCatalog();
      String schemaName=null;
      String schemaSeparator="String_Node_Str";
      if (metaDataProvider.isSchemaSupported()) {
        int index=-1;
        if ((index=tableName.lastIndexOf(schemaSeparator)) != -1) {
          schemaName=tableName.substring(0,index);
          tableName=tableName.substring(index + 1);
        }
      }
      if (item.getData() instanceof DbObject) {
        DbObject obj=(DbObject)item.getData();
        if (obj.getType() == DbObject.TABLE_TYPE || obj.getType() == DbObject.VIEW_TYPE) {
          ArrayList columnList=metaDataProvider.getColumns(catalogName,schemaName,tableName,null);
          TreeItem[] items=item.getItems();
          if (items != null) {
            for (int i=0; i < items.length; i++) {
              items[i].dispose();
            }
          }
          Utility.createTreeItems(item,columnList,SWT.NONE,columnImage);
        }
 else         if (obj.getType() == DbObject.PROCEDURE_TYPE) {
          ArrayList procedureList=metaDataProvider.getAllProcedure(catalogName,schemaName,getTailoredSearchText(searchTxt.getText()));
          TreeItem[] items=item.getItems();
          if (items != null) {
            for (int i=0; i < items.length; i++) {
              items[i].dispose();
            }
          }
          Utility.createTreeItems(item,procedureList,SWT.NONE,columnImage);
        }
      }
 else       if (item.getData() instanceof Procedure) {
        Procedure obj=(Procedure)item.getData();
{
          ArrayList columnList=metaDataProvider.getProcedureColumns(obj.getCatalog(),schemaName,tableName,getTailoredSearchText(null));
          TreeItem[] items=item.getItems();
          if (items != null) {
            for (int i=0; i < items.length; i++) {
              items[i].dispose();
            }
          }
          Utility.createTreeItems(item,columnList,SWT.NONE,columnImage);
        }
      }
    }
  }
);
}