Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Update copyright lines.
[simgrid.git] / examples / s4u / trace-host-user-variables / s4u-trace-host-user-variables.cpp
index 3160653..b0546e0 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (c) 2010-2020. The SimGrid Team. All rights reserved.          */
+/* Copyright (c) 2010-2021. 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. */
@@ -54,11 +54,11 @@ int main(int argc, char* argv[])
   e.run();
 
   // get user declared variables
-  unsigned int cursor;
-  char* variable;
   xbt_dynar_t host_variables = TRACE_get_host_variables();
   if (host_variables) {
     XBT_INFO("Declared host variables:");
+    unsigned int cursor;
+    char* variable;
     xbt_dynar_foreach (host_variables, cursor, variable) {
       XBT_INFO("%s", variable);
     }