Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Try to fix a compiler error seen on Flag2 job of jenkins
[simgrid.git] / examples / c / cloud-simple / cloud-simple.c
index 6ed17197b76555d0c95022d2beb01236c61881d7..83e38c2af5489d7bdb663ea0c09a8c297c9214bb 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2007-2021. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2007-2023. The SimGrid Team. All rights reserved.          */
 
 /* This program is free software; you can redistribute it and/or modify it
  * under the terms of the license (GNU LGPL) which comes with this package. */
@@ -64,7 +64,7 @@ static void communication_rx_fun(int argc, char* argv[])
   XBT_INFO("%s:%s to %s:%s => %g sec", sg_host_get_name(priv->tx_host), sg_actor_get_name(priv->tx_proc), host_name,
            pr_name, clock_end - priv->clock_sta);
 
-  free(priv);
+  xbt_free(priv);
 }
 
 static void launch_communication_worker(sg_host_t tx_host, sg_host_t rx_host)
@@ -72,10 +72,10 @@ static void launch_communication_worker(sg_host_t tx_host, sg_host_t rx_host)
   char* mbox = bprintf("MBOX:%s-%s", sg_host_get_name(tx_host), sg_host_get_name(rx_host));
 
   const char* tx_argv[] = {"comm_tx", mbox, NULL};
-  sg_actor_create("comm_tx", tx_host, communication_tx_fun, 2, (char**)tx_argv);
+  sg_actor_create_("comm_tx", tx_host, communication_tx_fun, 2, tx_argv);
 
   const char* rx_argv[] = {"comm_rx", mbox, NULL};
-  sg_actor_create("comm_rx", rx_host, communication_rx_fun, 2, (char**)rx_argv);
+  sg_actor_create_("comm_rx", rx_host, communication_rx_fun, 2, rx_argv);
 
   xbt_free(mbox);
 }