Bug 36526 ErrorDialog leaks a clipboard
Build: 2.1 The JFace ErrorDialog leaks a clipboard instance in the copyToClipboard method: private void copyToClipboard(){ StringBuffer statusBuffer = new StringBuffer(); populateCopyBuffer(status,statusBuffer,0); Clipboard clipboard = new Clipboard(list.getDisplay()); clipboard.setContents( new Object[] {statusBuffer.toString()}, new Transfer[] {TextTransfer.getInstance()} ); } clipboard.dispose() should be called at the end of this method.
bundles/org.eclipse.jface/src/org/eclipse/jface/dialogs/ErrorDialog.java
return false;
	}
	/**
	 * Toggles the unfolding of the details area.  This is triggered by
	 * the user pressing the details button.
	 */
	private void toggleDetailsArea() {
		Point windowSize = getShell().getSize();
		Point oldSize = getShell().computeSize(SWT.DEFAULT, SWT.DEFAULT);
		if (listCreated) {
			list.dispose();
			listCreated = false;
			detailsButton.setText(IDialogConstants.SHOW_DETAILS_LABEL);
		} else {
			list = createDropDownList((Composite) getContents());
			detailsButton.setText(IDialogConstants.HIDE_DETAILS_LABEL);
		}
		Point newSize = getShell().computeSize(SWT.DEFAULT, SWT.DEFAULT);
		getShell().setSize(
			new Point(windowSize.x, windowSize.y + (newSize.y - oldSize.y)));
	}
	/**
	 * Put the details of the status of the error onto the 
	 * stream.
	 * @param status
	 * @param buffer
	 * @param nesting
	 */
	private void populateCopyBuffer(
		IStatus status,