Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[trace] end must be called while surf configuration still exist
[simgrid.git] / src / simdag / sd_global.c
index c24ce29..29dbf96 100644 (file)
@@ -410,15 +410,16 @@ void SD_exit(void)
     xbt_free(sd_global);
     sd_global = NULL;
 
+#ifdef HAVE_TRACING
+  TRACE_end();
+#endif
+
     DEBUG0("Exiting Surf...");
     surf_exit();
   } else {
     WARN0("SD_exit() called, but SimDag is not running");
     /* we cannot use exceptions here because xbt is not running! */
   }
-#ifdef HAVE_TRACING
-  TRACE_end();
-#endif
 }
 
 /**