Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
fix a memleak by not creating things we never use
authorMartin Quinson <martin.quinson@loria.fr>
Wed, 24 Aug 2016 08:42:22 +0000 (10:42 +0200)
committerMartin Quinson <martin.quinson@loria.fr>
Wed, 24 Aug 2016 08:42:22 +0000 (10:42 +0200)
examples/msg/app-pmm/app-pmm.c

index dd5e22a..7ddb867 100644 (file)
@@ -240,8 +240,6 @@ static void task_cleanup(void *arg){
 
 int main(int argc, char *argv[])
 {
 
 int main(int argc, char *argv[])
 {
-  xbt_os_timer_t timer = xbt_os_timer_new();
-
   MSG_init(&argc, argv);
   const char *platform = "../../platforms/cluster.xml";
   if (argc > 1)
   MSG_init(&argc, argv);
   const char *platform = "../../platforms/cluster.xml";
   if (argc > 1)
@@ -259,9 +257,7 @@ int main(int argc, char *argv[])
     xbt_free(hostname);
   }
 
     xbt_free(hostname);
   }
 
-  xbt_os_cputimer_start(timer);
   msg_error_t res = MSG_main();
   msg_error_t res = MSG_main();
-  xbt_os_cputimer_stop(timer);
   XBT_INFO("Simulated time: %g", MSG_get_clock());
 
   return res != MSG_OK;
   XBT_INFO("Simulated time: %g", MSG_get_clock());
 
   return res != MSG_OK;