Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
[SMPI] Fixed portability issues with shm_open.
[simgrid.git] / src / smpi / smpi_bench.c
index 35971e2..d863016 100644 (file)
@@ -13,6 +13,7 @@
 #include "surf/surf.h"
 #include "simgrid/sg_config.h"
 #include "simgrid/modelchecker.h"
+#include "mc/mc_replay.h"
 
 #ifndef WIN32
 #include <sys/mman.h>
@@ -459,7 +460,7 @@ void *smpi_shared_malloc(size_t size, const char *file, int line)
 {
   void* mem;
   if (sg_cfg_get_boolean("smpi/use_shared_malloc")){
-    char *loc = bprintf("%zu_%s_%d", (size_t)getpid(), file, line);
+    char *loc = bprintf("/%zu_%s_%d", (size_t)getpid(), file, line);
     int fd;
     shared_data_t *data;
     loc = smpi_shared_alloc_hash(loc); /* hash loc, in order to have something