Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[trace] categories declaration must be after environment creation
[simgrid.git] / examples / msg / tracing / procmig.c
index edd2945..e43c83c 100644 (file)
@@ -50,11 +50,13 @@ int main(int argc, char *argv[])
               argv[0]);
     exit(1);
   }
-  TRACE_category_with_color ("emigrant", "1 0 0");
 
   /* Simulation setting */
   MSG_create_environment(argv[1]);
 
+  /* declaring tracing category for the process (after environment creation) */
+  TRACE_category_with_color ("emigrant", "1 0 0");
+
   /* Application deployment */
   MSG_function_register("emigrant", emigrant);
   MSG_launch_application(argv[2]);