Project: Eclipse_Platform_UI
Bug 385267 Change exception message
Reported: 2012-07-17 04:27:43 | Status: verified fixed

Build Identifier: if the name of the Binding Context is empty, the Nullpointer Exception should be "The name of a binding context cannot be null" instead of "The name of a scheme cannot be null" org.eclipse.e4.core.di.InjectionException: java.lang.NullPointerException: The name of a scheme cannot be null at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:63) at org.eclipse.e4.core.internal.di.InjectorImpl.processAnnotated(InjectorImpl.java:857) at org.eclipse.e4.core.internal.di.InjectorImpl.inject(InjectorImpl.java:111) at org.eclipse.e4.core.internal.di.InjectorImpl.internalMake(InjectorImpl.java:318) at org.eclipse.e4.core.internal.di.InjectorImpl.make(InjectorImpl.java:253) at org.eclipse.e4.core.contexts.ContextInjectionFactory.make(ContextInjectionFactory.java:185) at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.createFromBundle(ReflectionContributionFactory.java:105) at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.doCreate(ReflectionContributionFactory.java:71) at org.eclipse.e4.ui.internal.workbench.ReflectionContributionFactory.create(ReflectionContributionFactory.java:49) at org.eclipse.e4.ui.internal.workbench.swt.E4Application.createE4Workbench(E4Application.java:254) at org.eclipse.e4.ui.internal.workbench.swt.E4Application.start(E4Application.java:132) at org.eclipse.equinox.internal.app.EclipseAppHandle.run(EclipseAppHandle.java:196) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.runApplication(EclipseAppLauncher.java:110) at org.eclipse.core.runtime.internal.adaptor.EclipseAppLauncher.start(EclipseAppLauncher.java:79) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:353) at org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseStarter.java:180) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.eclipse.equinox.launcher.Main.invokeFramework(Main.java:629) at org.eclipse.equinox.launcher.Main.basicRun(Main.java:584) at org.eclipse.equinox.launcher.Main.run(Main.java:1438) at org.eclipse.equinox.launcher.Main.main(Main.java:1414) Caused by: java.lang.NullPointerException: The name of a scheme cannot be null at org.eclipse.core.commands.contexts.Context.define(Context.java:140) at org.eclipse.e4.ui.internal.workbench.addons.ContextProcessingAddon.defineContexts(ContextProcessingAddon.java:65) at org.eclipse.e4.ui.internal.workbench.addons.ContextProcessingAddon.defineContexts(ContextProcessingAddon.java:54) at org.eclipse.e4.ui.internal.workbench.addons.ContextProcessingAddon.init(ContextProcessingAddon.java:47) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source) at java.lang.reflect.Method.invoke(Unknown Source) at org.eclipse.e4.core.internal.di.MethodRequestor.execute(MethodRequestor.java:56) ... 23 more Reproducible: Always Steps to Reproduce: 1.Create Binding Context 2.let the Name label empty 3.start application

Files changed in fix:
bundles/org.eclipse.core.commands/src/org/eclipse/core/commands/contexts/Context.java