Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
introduce sg_actor_create and use it in C examples
[simgrid.git] / examples / c / energy-exec-ptask / energy-exec-ptask.c
index f4e9888..1078fbd 100644 (file)
@@ -95,8 +95,7 @@ int main(int argc, char* argv[])
   sg_host_t first_host = all_hosts[0];
   free(all_hosts);
 
-  sg_actor_t actor = sg_actor_init("test", first_host);
-  sg_actor_start(actor, runner, 0, NULL);
+  sg_actor_create("test", first_host, runner, 0, NULL);
 
   simgrid_run();
   XBT_INFO("Simulation done.");