return false if interrupted

Project: http://git-wip-us.apache.org/repos/asf/curator/repo
Commit: http://git-wip-us.apache.org/repos/asf/curator/commit/38011678
Tree: http://git-wip-us.apache.org/repos/asf/curator/tree/38011678
Diff: http://git-wip-us.apache.org/repos/asf/curator/diff/38011678

Branch: refs/heads/CURATOR-247
Commit: 38011678c4faebb1cd9388e56f0d13d29862c609
Parents: 35b2063
Author: randgalt <randg...@apache.org>
Authored: Mon Aug 31 07:19:21 2015 -0700
Committer: randgalt <randg...@apache.org>
Committed: Mon Aug 31 07:19:21 2015 -0700

----------------------------------------------------------------------
 .../src/main/java/org/apache/curator/retry/RetryForever.java      | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/curator/blob/38011678/curator-client/src/main/java/org/apache/curator/retry/RetryForever.java
----------------------------------------------------------------------
diff --git 
a/curator-client/src/main/java/org/apache/curator/retry/RetryForever.java 
b/curator-client/src/main/java/org/apache/curator/retry/RetryForever.java
index 89f0276..59f3d0d 100644
--- a/curator-client/src/main/java/org/apache/curator/retry/RetryForever.java
+++ b/curator-client/src/main/java/org/apache/curator/retry/RetryForever.java
@@ -51,8 +51,9 @@ public class RetryForever implements RetryPolicy
         }
         catch (InterruptedException e)
         {
-            log.warn("Error occurred while sleeping", e);
             Thread.currentThread().interrupt();
+            log.warn("Error occurred while sleeping", e);
+            return false;
         }
         return true;
     }

Reply via email to