- simdata = host->simdata;
-
- xbt_assert0((xbt_swag_size(simdata->process_list)==0),
- "Some process are still running on this host");
- xbt_swag_free(simdata->process_list);
+ if (xbt_swag_size(host->process_list) != 0) {
+ char *msg = bprintf("Shutting down host %s, but it's not empty:", host->name);
+ char *tmp;
+ smx_process_t process = NULL;
+
+ xbt_swag_foreach(process, host->process_list) {
+ tmp = bprintf("%s\n\t%s", msg, process->name);
+ free(msg);
+ msg = tmp;
+ }
+ THROW1(arg_error, 0, "%s", msg);
+ }