X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/dd05e77cf9fe231aef1608d42c8e45ac3ee5c15c..1aa6ab8ad6fc7929a1b2102f1e753338c4fb0b20:/teshsuite/s4u/host_on_off_wait/host_on_off_wait.cpp?ds=sidebyside diff --git a/teshsuite/s4u/host_on_off_wait/host_on_off_wait.cpp b/teshsuite/s4u/host_on_off_wait/host_on_off_wait.cpp index 280536ee27..e8617e07e7 100644 --- a/teshsuite/s4u/host_on_off_wait/host_on_off_wait.cpp +++ b/teshsuite/s4u/host_on_off_wait/host_on_off_wait.cpp @@ -21,9 +21,11 @@ static void master() static void worker() { XBT_INFO("Worker waiting"); - // TODO, This should really be MSG_HOST_FAILURE - simgrid::s4u::this_actor::sleep_for(5); - XBT_ERROR("Worker should be off already."); + try { + simgrid::s4u::this_actor::sleep_for(5); + } catch (simgrid::HostFailureException& e) { + XBT_INFO("The host has died ... as expected."); + } } int main(int argc, char* argv[])