1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-06-05 00:36:16 +02:00

Bug 549066 - NPE in Launch Bar injection when running headless.

Adds a check that we actually got an application before doing the
injection.

Change-Id: Ie3670f1c35d107f8147799a449498e03b950ac00
This commit is contained in:
Doug Schaefer 2019-07-15 10:09:06 -04:00
parent 578bfc472d
commit 236be726c4

View file

@ -38,6 +38,11 @@ public class LaunchBarInjector {
@Execute
void execute() {
if (application == null) {
// We are running headless, don't need the launch bar here.
return;
}
IPreferenceStore store = Activator.getDefault().getPreferenceStore();
boolean enabled = store.getBoolean(Activator.PREF_ENABLE_LAUNCHBAR);
injectIntoAll(enabled);