core: properly yield in locker

This commit is contained in:
Mitchell Hashimoto 2014-05-08 09:57:52 -07:00
parent 86aef2249b
commit 4e52facebc
1 changed files with 1 additions and 1 deletions

View File

@ -154,7 +154,7 @@ module Vagrant
# We only lock if we're not executing an SSH action. In the future
# we will want to do more fine-grained unlocking in actions themselves
# but for a 1.6.2 release this will work.
locker = Proc.new { |*args| yield }
locker = Proc.new { |*args, &block| block.call }
locker = @env.method(:lock) if !name.to_s.start_with?("ssh")
# Lock this machine for the duration of this action