Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Parameter for cleanup callback won't be null.
[simgrid.git] / teshsuite / msg / host_on_off_processes / host_on_off_processes.cpp
index 87cb748..b4a467a 100644 (file)
@@ -15,8 +15,7 @@ int tasks_done = 0;
 
 static void task_cleanup_handler(void* task)
 {
-  if (task)
-    MSG_task_destroy(static_cast<msg_task_t>(task));
+  MSG_task_destroy(static_cast<msg_task_t>(task));
 }
 
 static int process_daemon(int /*argc*/, char** /*argv*/)
@@ -108,7 +107,7 @@ static int test_launcher(int /*argc*/, char** /*argv*/)
   }
 
   test = 3;
-  // Create a process running sucessive sleeps on a host and turn the host off during the execution of the process.
+  // Create a process running successive sleeps on a host and turn the host off during the execution of the process.
   if (xbt_dynar_search_or_negative(tests, &test) != -1) {
     xbt_die("Test 3 is superseeded by activity-lifecycle");
   }
@@ -156,7 +155,6 @@ static int test_launcher(int /*argc*/, char** /*argv*/)
   test = 6;
   if (xbt_dynar_search_or_negative(tests, &test) != -1) {
     XBT_INFO("Test 6: Turn on Jupiter, assign a VM on Jupiter, launch a process inside the VM, and turn off the node");
-    MSG_process_set_data_cleanup(nullptr); // If set for test 6, cleanup handler gives double-free errors.
 
     // Create VM0
     msg_vm_t vm0 = MSG_vm_create_core(jupiter, "vm0");