Bug 300372 [Commands] Doing Ctrl+3 build id command fails with InvalidArgumentException
3.5.2 RC1 Doing Ctrl + 3, followed by build id fails with the following exception: java.lang.IllegalArgumentException: Argument not valid at org.eclipse.swt.SWT.error(SWT.java:3865) at org.eclipse.swt.SWT.error(SWT.java:3799) at org.eclipse.swt.SWT.error(SWT.java:3770) at org.eclipse.swt.dnd.DND.error(DND.java:282) at org.eclipse.swt.dnd.DND.error(DND.java:228) at org.eclipse.swt.dnd.Clipboard.setContents(Clipboard.java:440) at org.eclipse.swt.dnd.Clipboard.setContents(Clipboard.java:371) at org.eclipse.ui.internal.ide.commands.CopyBuildIdToClipboardHandler.ex ecute(CopyBuildIdToClipboardHandler.java:45) at org.eclipse.ui.internal.handlers.HandlerProxy.execute(HandlerProxy.ja va:294) at org.eclipse.core.commands.Command.executeWithChecks(Command.java:476) at org.eclipse.core.commands.ParameterizedCommand.executeWithChecks(Para meterizedCommand.java:508) at org.eclipse.ui.internal.handlers.HandlerService.executeCommandInConte xt(HandlerService.java:270) at org.eclipse.ui.internal.quickaccess.CommandElement.execute(CommandEle ment.java:49) at org.eclipse.ui.internal.quickaccess.QuickAccessDialog.handleElementSe lected(QuickAccessDialog.java:681) at org.eclipse.ui.internal.quickaccess.QuickAccessDialog.handleSelection (QuickAccessDialog.java:758) at org.eclipse.ui.internal.quickaccess.QuickAccessDialog.access$6(QuickA ccessDialog.java:748)
bundles/org.eclipse.ui.ide/src/org/eclipse/ui/internal/ide/commands/CopyBuildIdToClipboardHandler.java
/*
	 * (non-Javadoc)
	 * 
	 * @see org.eclipse.core.commands.IHandler#execute(org.eclipse.core.commands.ExecutionEvent)
	 */
	public Object execute(ExecutionEvent event) throws ExecutionException {
		final String buildId = ConfigurationInfo.getBuildId();
		if (buildId == null)
			throw new ExecutionException("No build ID in this instance."); 
		Clipboard clipboard = null;
		try {
			clipboard = new Clipboard(HandlerUtil.getActiveShell(event)
					.getDisplay());
			clipboard.setContents(new Object[] { buildId },
					new Transfer[] { TextTransfer.getInstance() });
		} finally {
			if (clipboard != null) {
				clipboard.dispose();
			}
		}
		return null;
	}
}