Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Kill now unused xbt_heap.
[simgrid.git] / src / mc / mc_global.cpp
index 0204bbd..cd9f830 100644 (file)
 #if SIMGRID_HAVE_MC
 #include "src/mc/checker/Checker.hpp"
 #include "src/mc/mc_comm_pattern.hpp"
-#include "src/mc/mc_private.h"
-#include "src/mc/mc_request.h"
-#include "src/mc/mc_safety.h"
-#include "src/mc/mc_smx.h"
-#include "src/mc/mc_snapshot.h"
-#include "src/mc/mc_unw.h"
+#include "src/mc/mc_private.hpp"
+#include "src/mc/mc_request.hpp"
+#include "src/mc/mc_safety.hpp"
+#include "src/mc/mc_smx.hpp"
+#include "src/mc/mc_snapshot.hpp"
+#include "src/mc/mc_unw.hpp"
 #include <libunwind.h>
 #endif
 
 #include "src/mc/Transition.hpp"
-#include "src/mc/mc_record.h"
+#include "src/mc/mc_record.hpp"
 #include "src/mc/remote/Client.hpp"
 #include "src/mc/remote/mc_protocol.h"
 
 XBT_LOG_NEW_DEFAULT_SUBCATEGORY(mc_global, mc, "Logging specific to MC (global)");
 
+extern std::string _sg_mc_dot_output_file;
+
 namespace simgrid {
 namespace mc {
 
@@ -76,7 +78,7 @@ FILE *dot_output = nullptr;
 
 void MC_init_dot_output()
 {
-  dot_output = fopen(_sg_mc_dot_output_file, "w");
+  dot_output = fopen(_sg_mc_dot_output_file.c_str(), "w");
 
   if (dot_output == nullptr) {
     perror("Error open dot output file");
@@ -163,7 +165,8 @@ static void MC_dump_stacks(FILE* file)
 {
   int nstack = 0;
   for (auto const& stack : mc_model_checker->process().stack_areas()) {
-    fprintf(file, "Stack %i:\n", nstack++);
+    fprintf(file, "Stack %i:\n", nstack);
+    nstack++;
 
     simgrid::mc::UnwindContext context;
     unw_context_t raw_context =