Author: kfujino
Date: Wed Sep 19 08:42:33 2012
New Revision: 1387486
URL: http://svn.apache.org/viewvc?rev=1387486&view=rev
Log:
The "running" flag is moved out of "if" block.
Modified:
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpPingInterceptor.java
Modified:
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpPingInterceptor.java
URL:
http://svn.apache.org/viewvc/tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpPingInterceptor.java?rev=1387486&r1=1387485&r2=1387486&view=diff
==============================================================================
---
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpPingInterceptor.java
(original)
+++
tomcat/trunk/java/org/apache/catalina/tribes/group/interceptors/TcpPingInterceptor.java
Wed Sep 19 08:42:33 2012
@@ -64,8 +64,8 @@ public class TcpPingInterceptor extends
@Override
public synchronized void start(int svc) throws ChannelException {
super.start(svc);
+ running = true;
if ( thread == null && useThread) {
- running = true;
thread = new PingThread();
thread.setDaemon(true);
thread.setName("TcpPingInterceptor.PingThread-"+cnt.addAndGet(1));
@@ -86,8 +86,8 @@ public class TcpPingInterceptor extends
@Override
public void stop(int svc) throws ChannelException {
+ running = false;
if ( thread != null ) {
- running = false;
thread.interrupt();
thread = null;
}
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]