]> AND Public Git Repository - simgrid.git/blobdiff - examples/msg/actions/actions.c
Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
stupid old gcc. That's initialized.
[simgrid.git] / examples / msg / actions / actions.c
index 91d63eef522d801fda95341aeeeb12183cdc1041..af2465127231bcc493c83d3fc62862ffd8cb5ff9 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2009-2013. The SimGrid Team.
+/* Copyright (c) 2009-2014. The SimGrid Team.
  * All rights reserved.                                                     */
 
 /* This program is free software; you can redistribute it and/or modify it
@@ -108,7 +108,7 @@ static void action_send(const char *const *action)
 
   sprintf(to, "%s_%s", MSG_process_get_name(MSG_process_self()), action[2]);
 
-  ACT_DEBUG("Entering Send: %s (size: %lg)", NAME, size);
+  ACT_DEBUG("Entering Send: %s (size: %g)", NAME, size);
   if (size < 65536) {
     action_Isend(action);
   } else {
@@ -479,6 +479,9 @@ int main(int argc, char *argv[])
 
   /* Check the given arguments */
   MSG_init(&argc, argv);
+  /* Explicit initialization of the action module is required now*/
+  MSG_action_init();
+
   if (argc < 3) {
     printf("Usage: %s platform_file deployment_file [action_files]\n", argv[0]);
     printf
@@ -522,6 +525,9 @@ int main(int argc, char *argv[])
 
   XBT_INFO("Simulation time %g", MSG_get_clock());
 
+  /* Explicit finalization of the action module is required now*/
+  MSG_action_exit();
+
   if (res == MSG_OK)
     return 0;
   else