Logo AND Algorithmique Numérique Distribuée

Public GIT Repository
Use xbt_malloc (and friends) instead of direct malloc()
[simgrid.git] / src / mc / mc_liveness.c
index b80b319..7056018 100644 (file)
@@ -41,7 +41,7 @@ int create_dump(int pair)
     if(wait(&status) < 0)
       perror("wait");
     if(WIFSIGNALED(status) && WCOREDUMP(status)){
     if(wait(&status) < 0)
       perror("wait");
     if(WIFSIGNALED(status) && WCOREDUMP(status)){
-      char *core_name = malloc(20);
+      char *core_name = xbt_malloc(20);
       sprintf(core_name,"core_%d", pair); 
       rename("core", core_name);
       free(core_name);
       sprintf(core_name,"core_%d", pair); 
       rename("core", core_name);
       free(core_name);