#include "simgrid/simdag.h"
#include "xbt/file.h"
-#include <stdio.h>
-#include <string.h>
XBT_LOG_NEW_DEFAULT_CATEGORY(test, "Logging specific to this SimDag example");
if (!dax){
XBT_ERROR("A problem occurred during DAX parsing (cycle or syntax). Do not continue this test");
free(tracefilename);
- SD_exit();
+
exit(255);
}
XBT_INFO("------------------- Run the schedule ---------------------------");
SD_simulate(-1);
XBT_INFO("------------------- Produce the trace file---------------------------");
- XBT_INFO("Producing the trace of the run into %s", xbt_basename(tracefilename));
+ char * basename = xbt_basename(tracefilename);
+ XBT_INFO("Producing the trace of the run into %s", basename);
+ free(basename);
FILE *out = fopen(tracefilename, "w");
xbt_assert(out, "Cannot write to %s", tracefilename);
free(tracefilename);
fclose(out);
xbt_dynar_free_container(&dax);
- SD_exit();
return 0;
}