core: raise exceptions if they happen in WaitForCommunicator threads

This commit is contained in:
Mitchell Hashimoto 2014-01-03 10:57:04 -08:00
parent d1fdee7ae3
commit 664aaa0088
1 changed files with 4 additions and 0 deletions

View File

@ -56,6 +56,10 @@ module Vagrant
return if env[:interrupted] return if env[:interrupted]
end end
# Join so that they can raise exceptions if there were any
ready_thr.join if !ready_thr.alive?
states_thr.join if !states_thr.alive?
# If it went into a bad state, then raise an error # If it went into a bad state, then raise an error
if !states_thr[:result] if !states_thr[:result]
raise Errors::VMBootBadState, raise Errors::VMBootBadState,