You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@camel.apache.org by js...@apache.org on 2007/07/30 18:47:27 UTC

svn commit: r561037 - /activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/ServiceSupport.java

Author: jstrachan
Date: Mon Jul 30 09:47:26 2007
New Revision: 561037

URL: http://svn.apache.org/viewvc?view=rev&rev=561037
Log:
applied patch from Hadrian Zbarcea for CAMEL-81 to fix the lifecycle logic

Modified:
    activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/ServiceSupport.java

Modified: activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/ServiceSupport.java
URL: http://svn.apache.org/viewvc/activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/ServiceSupport.java?view=diff&rev=561037&r1=561036&r2=561037
==============================================================================
--- activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/ServiceSupport.java (original)
+++ activemq/camel/trunk/camel-core/src/main/java/org/apache/camel/impl/ServiceSupport.java Mon Jul 30 09:47:26 2007
@@ -40,8 +40,7 @@
     }
 
     public void stop() throws Exception {
-        if (stopped.compareAndSet(false, true)) {
-            stopping.set(true);
+        if (started.get() && stopping.compareAndSet(false, true)) {
             try {
                 doStop();
             }