Fixes for restart/stop.

This commit is contained in:
Julien Fontanet 2014-02-06 16:32:54 +01:00
parent 1b55746213
commit 8c706d2393

View File

@ -380,8 +380,8 @@ exports.restart = ->
try
# Attempts a clean reboot.
xapi.call 'VM.clean_reboot', VM.ref
catch e
throw e unless
catch error
throw error unless error[0] is 'VM_MISSING_PV_DRIVERS'
xapi.call 'VM.hard_reboot', VM.ref
@ -425,8 +425,8 @@ exports.stop = ->
try
# Attempts a clean shutdown.
xapi.call 'VM.clean_shutdown', VM.ref
catch e
throw e unless
catch error
throw error unless error[0] is 'VM_MISSING_PV_DRIVERS'
xapi.call 'VM.hard_shutdown', VM.ref