From 140bac81aeeea0358cdf2f33398d932240ef361f Mon Sep 17 00:00:00 2001 From: Roman Ivanov Date: Sat, 7 Dec 2013 23:09:20 -0800 Subject: [PATCH] patch from SourceForge issue 520 was applied --- .../checkstyle/filters/SuppressionCommentFilter.java | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/checkstyle/com/puppycrawl/tools/checkstyle/filters/SuppressionCommentFilter.java b/src/checkstyle/com/puppycrawl/tools/checkstyle/filters/SuppressionCommentFilter.java index 6ae8e6c93..ba8235dab 100644 --- a/src/checkstyle/com/puppycrawl/tools/checkstyle/filters/SuppressionCommentFilter.java +++ b/src/checkstyle/com/puppycrawl/tools/checkstyle/filters/SuppressionCommentFilter.java @@ -203,13 +203,13 @@ public class SuppressionCommentFilter final Matcher tagMatcher = mTagCheckRegexp.matcher(aEvent.getSourceName()); if (tagMatcher.find()) { + if (mTagMessageRegexp != null) { + final Matcher messageMatcher = + mTagMessageRegexp.matcher(aEvent.getMessage()); + return messageMatcher.find(); + } return true; } - if (mTagMessageRegexp != null) { - final Matcher messageMatcher = - mTagMessageRegexp.matcher(aEvent.getMessage()); - return messageMatcher.find(); - } return false; }