Bug 114550 IndexOutOfBoundsException in Problems Hierarchal Mode
20051101 I am not sure how I got this but I was switching to the ColorSelector.java in hierarchal mode (which has no hierarchy) Caused by: java.lang.ArrayIndexOutOfBoundsException: 0 at org.eclipse.ui.views.markers.internal.MarkerAdapter.buildHierarchy(MarkerAdapter.java:308) at org.eclipse.ui.views.markers.internal.MarkerAdapter$MarkerCategory.getChildren(MarkerAdapter.java:89) at org.eclipse.ui.views.markers.internal.MarkerTreeContentProvider.getChildren(MarkerTreeContentProvider.java:71) at org.eclipse.jface.viewers.AbstractTreeViewer.getRawChildren(AbstractTreeViewer.java:899) at org.eclipse.jface.viewers.StructuredViewer.getFilteredChildren(StructuredViewer.java:790) at org.eclipse.jface.viewers.StructuredViewer.getSortedChildren(StructuredViewer.java:905) at org.eclipse.jface.viewers.AbstractTreeViewer$1.run(AbstractTreeViewer.java:512) at org.eclipse.swt.custom.BusyIndicator.showWhile(BusyIndicator.java:69) at org.eclipse.jface.viewers.AbstractTreeViewer.createChildren(AbstractTreeViewer.java:494) at org.eclipse.jface.viewers.AbstractTreeViewer.internalExpandToLevel(AbstractTreeViewer.java:1122) at org.eclipse.jface.viewers.AbstractTreeViewer.internalExpandToLevel(AbstractTreeViewer.java:1131) at org.eclipse.jface.viewers.AbstractTreeViewer.expandToLevel(AbstractTreeViewer.java:658) at org.eclipse.jface.viewers.AbstractTreeViewer.expandToLevel(AbstractTreeViewer.java:641) at org.eclipse.jface.viewers.AbstractTreeViewer.expandAll(AbstractTreeViewer.java:630) at org.eclipse.ui.views.markers.internal.MarkerView$7.runInUIThread(MarkerView.java:1280) at org.eclipse.ui.progress.UIJob$1.run(UIJob.java:93) at org.eclipse.swt.widgets.RunnableLock.run(RunnableLock.java:35) at org.eclipse.swt.widgets.Synchronizer.runAsyncMessages(Synchronizer.java:123) ... 18 more
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/views/markers/internal/MarkerAdapter.java
if (markerLimit != -1) {
			monitor.subTask(MarkerMessages.MarkerView_18);
			SubProgressMonitor mon = new SubProgressMonitor(monitor, 40);
			lastMarkers = SortUtil.getFirst(lastMarkers, (TableSorter) view
					.getViewer().getSorter(), markerLimit, mon);
			if (monitor.isCanceled())
				return;
		}
		monitor.subTask(MarkerMessages.MarkerView_queueing_updates);
		SubProgressMonitor sub = new SubProgressMonitor(monitor, 50);
		if (view.isHierarchalMode()) {
			view.getTableSorter().sort(view.getViewer(), lastMarkers);
			MarkerCategory[] categories = buildHierarchy(lastMarkers, 0,
					lastMarkers.getSize() - 1, 0, null);
			if (categories == null)
				collector.add(lastMarkers.toArray(), sub);
			else
				collector.add(categories, sub);
		} else
			collector.add(lastMarkers.toArray(), sub);
		if (monitor.isCanceled())
			return;
		monitor.done();
		
	}
	/**
	 * Add the children of object to collector.
	 * 
	 * @param object
	 * @param collector