1
0
Fork 0
mirror of https://github.com/eclipse-cdt/cdt synced 2025-07-31 12:55:40 +02:00

Bug 485549 - prevent ArrayIndexOutOfBoundsException if no services are

installed.

Change-Id: I96249643103ea9427b1c5d165d8854e50984f614
Signed-off-by: Greg Watson <g.watson@computer.org>
This commit is contained in:
Greg Watson 2016-01-11 09:00:19 -05:00
parent 839a9b61c3
commit 881ca83b43

View file

@ -386,6 +386,7 @@ public class ConnectionsPreferencePage extends PreferencePage implements IWorkbe
fCloseButton.addSelectionListener(fEventHandler);
fCloseButton.setEnabled(false);
if (fServiceIDs.length > 0) {
String id = Preferences.getString(IRemotePreferenceConstants.PREF_CONNECTION_TYPE_ID);
if ("".equals(id)) { //$NON-NLS-1$
id = fServiceIDs[0];
@ -396,6 +397,7 @@ public class ConnectionsPreferencePage extends PreferencePage implements IWorkbe
}
}
selectServices(id);
}
return preferencePane;
}