about summary refs log tree commit homepage
path: root/lib/raindrops/aggregate/pmq.rb
diff options
context:
space:
mode:
authorEric Wong <bofh@yhbt.net>2020-01-06 09:54:50 +0000
committerEric Wong <e@80x24.org>2020-01-06 09:56:28 +0000
commit85486f9af18e4f249f23253e3b251e685b323912 (patch)
treebb98971324a6416d782ec3deab39e4b404cda6c3 /lib/raindrops/aggregate/pmq.rb
parent6ec35b0be879970931a67f5aa84b0e12099b12fd (diff)
downloadraindrops-85486f9af18e4f249f23253e3b251e685b323912.tar.gz
Newer rubies have more warnings
Diffstat (limited to 'lib/raindrops/aggregate/pmq.rb')
-rw-r--r--lib/raindrops/aggregate/pmq.rb12
1 files changed, 6 insertions, 6 deletions
diff --git a/lib/raindrops/aggregate/pmq.rb b/lib/raindrops/aggregate/pmq.rb
index 8623cb1..64d0a4f 100644
--- a/lib/raindrops/aggregate/pmq.rb
+++ b/lib/raindrops/aggregate/pmq.rb
@@ -142,8 +142,8 @@ class Raindrops::Aggregate::PMQ
       warn "Unhandled exception in #{__FILE__}:#{__LINE__}: #{e}"
       break
     end while true
-    ensure
-      flush_master
+  ensure
+    flush_master
   end
 
   # Loads the last shared \Aggregate from the master thread/process
@@ -175,14 +175,14 @@ class Raindrops::Aggregate::PMQ
   # worker thread or process
   def stop_master_loop
     sleep 0.1 until mq_send(false)
-    rescue Errno::EINTR
-      retry
+  rescue Errno::EINTR
+    retry
   end
 
   def lock! io, type # :nodoc:
     io.fcntl Fcntl::F_SETLKW, type
-    rescue Errno::EINTR
-      retry
+  rescue Errno::EINTR
+    retry
   end
 
   # we use both a mutex for thread-safety and fcntl lock for process-safety