Skip to main content
aboutsummaryrefslogtreecommitdiffstats
path: root/codan
diff options
context:
space:
mode:
authorMarc-Andre Laperle2013-01-01 21:31:18 +0000
committerMarc-Andre Laperle2013-01-01 21:38:26 +0000
commit78f863bc01f14da837b73ca9e4cb68d0639cd9d2 (patch)
tree5fc093665482c9b961ae7f8039583c817beaa4ab /codan
parent53012d05af62f708397a9a955f175515ff1dbe90 (diff)
downloadorg.eclipse.cdt-78f863bc01f14da837b73ca9e4cb68d0639cd9d2.tar.gz
org.eclipse.cdt-78f863bc01f14da837b73ca9e4cb68d0639cd9d2.tar.xz
org.eclipse.cdt-78f863bc01f14da837b73ca9e4cb68d0639cd9d2.zip
Bug 396749 - Checker is not enabled if only one problem is selected
Diffstat (limited to 'codan')
-rw-r--r--codan/org.eclipse.cdt.codan.core/src/org/eclipse/cdt/codan/internal/core/CheckersRegistry.java6
1 files changed, 2 insertions, 4 deletions
diff --git a/codan/org.eclipse.cdt.codan.core/src/org/eclipse/cdt/codan/internal/core/CheckersRegistry.java b/codan/org.eclipse.cdt.codan.core/src/org/eclipse/cdt/codan/internal/core/CheckersRegistry.java
index 6e34549c8a8..89ec54fe986 100644
--- a/codan/org.eclipse.cdt.codan.core/src/org/eclipse/cdt/codan/internal/core/CheckersRegistry.java
+++ b/codan/org.eclipse.cdt.codan.core/src/org/eclipse/cdt/codan/internal/core/CheckersRegistry.java
@@ -1,5 +1,5 @@
/*******************************************************************************
- * Copyright (c) 2009, 2011 Alena Laskavaia
+ * Copyright (c) 2009, 2013 Alena Laskavaia
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
@@ -417,9 +417,7 @@ public class CheckersRegistry implements Iterable<IChecker>, ICheckersRegistry {
IProblem problem = resourceProfile.findProblem(p.getId());
if (problem == null)
throw new IllegalArgumentException(p.getId() + " is not registered"); //$NON-NLS-1$
- if (!problem.isEnabled())
- return false;
- if (checker instanceof AbstractCheckerWithProblemPreferences) {
+ if (problem.isEnabled() && checker instanceof AbstractCheckerWithProblemPreferences) {
LaunchModeProblemPreference pref =
((AbstractCheckerWithProblemPreferences) checker).getLaunchModePreference(problem);
if (pref.isRunningInMode(mode)) {

Back to the top