diff options
author | Michael Valenta | 2005-09-20 15:18:40 +0000 |
---|---|---|
committer | Michael Valenta | 2005-09-20 15:18:40 +0000 |
commit | 0ad3573104ea1f7a3af034177bfd41e8fe6fabaa (patch) | |
tree | 1cb22f108585ef5c7278e5d879568f34ecce2534 /bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java | |
parent | 7be5075272e910d30828191695fe258d6a5ed695 (diff) | |
download | eclipse.platform.team-0ad3573104ea1f7a3af034177bfd41e8fe6fabaa.tar.gz eclipse.platform.team-0ad3573104ea1f7a3af034177bfd41e8fe6fabaa.tar.xz eclipse.platform.team-0ad3573104ea1f7a3af034177bfd41e8fe6fabaa.zip |
Bug 110025 NPE calling Team.setAllIgnores()
Diffstat (limited to 'bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java')
-rw-r--r-- | bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java b/bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java index dab659eb4..b2a29630c 100644 --- a/bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java +++ b/bundles/org.eclipse.team.core/src/org/eclipse/team/core/Team.java @@ -146,6 +146,12 @@ public final class Team { // The ignores are cached and when the preferences change the // cache is cleared. This makes it faster to lookup without having // to re-parse the preferences. + initializeIgnores(); + IIgnoreInfo[] result = getIgnoreInfo(globalIgnore); + return result; + } + + private static void initializeIgnores() { if (globalIgnore == null) { globalIgnore = new TreeMap(); pluginIgnore = new TreeMap(); @@ -157,8 +163,6 @@ public final class Team { } initializePluginIgnores(pluginIgnore, globalIgnore); } - IIgnoreInfo[] result = getIgnoreInfo(globalIgnore); - return result; } private static IIgnoreInfo[] getIgnoreInfo(Map gIgnore) { @@ -222,6 +226,7 @@ public final class Team { * Add patterns to the list of global ignores. */ public static void setAllIgnores(String[] patterns, boolean[] enabled) { + initializeIgnores(); globalIgnore = new TreeMap(); ignoreMatchers = null; for (int i = 0; i < patterns.length; i++) { |