tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Francis Galiegue <fgalie...@gmail.com>
Subject [PATCH] Fix suspicious logic operator usage
Date Wed, 05 Oct 2011 10:33:54 GMT
Found by FindBugs. startService() and stopService() both return boolean, so it
is likely that the '&' is a typo and '&&' was meant.
---
 .../tribes/membership/McastServiceImpl.java        |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/java/org/apache/catalina/tribes/membership/McastServiceImpl.java b/java/org/apache/catalina/tribes/membership/McastServiceImpl.java
index 8569ed4..5e59700 100644
--- a/java/org/apache/catalina/tribes/membership/McastServiceImpl.java
+++ b/java/org/apache/catalina/tribes/membership/McastServiceImpl.java
@@ -631,7 +631,7 @@ public class McastServiceImpl
                 while (!success) {
                     if(log.isInfoEnabled())
                         log.info("Tribes membership, running recovery thread, multicasting
is not functional.");
-                    if (stopService() & startService()) {
+                    if (stopService() && startService()) {
                         success = true;
                         if(log.isInfoEnabled())
                             log.info("Membership recovery was successful.");
-- 
1.7.6.1


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tomcat.apache.org
For additional commands, e-mail: dev-help@tomcat.apache.org


Mime
View raw message