From d1912c811f50957db298a3a3b1121efa3bf45909 Mon Sep 17 00:00:00 2001 From: John Bender Date: Tue, 9 Feb 2010 07:25:03 -0800 Subject: [PATCH] changed rescue to ensure block in Busy.busy --- lib/hobo/busy.rb | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib/hobo/busy.rb b/lib/hobo/busy.rb index 0ac41c00e..1120c8981 100644 --- a/lib/hobo/busy.rb +++ b/lib/hobo/busy.rb @@ -31,6 +31,11 @@ module Hobo Busy.busy = false end end + + # In the case were an exception is thrown by the wrapped code + # make sure to set busy to sane state and reraise the error + ensure + Busy.busy = false end end end