X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/1ab3563b9f429a75fbbdc95c6d3405fc4368d876..5ce5e2ee7fd0dd8344be0823d7bd7c4abb16b284:/src/gras/Msg/msg.c?ds=sidebyside diff --git a/src/gras/Msg/msg.c b/src/gras/Msg/msg.c index c669fbdf4d..a041dba75b 100644 --- a/src/gras/Msg/msg.c +++ b/src/gras/Msg/msg.c @@ -79,6 +79,12 @@ void gras_msg_init(void) { memcpy(_GRAS_header,"GRAS", 4); _GRAS_header[4]=GRAS_PROTOCOL_VERSION; _GRAS_header[5]=(char)GRAS_THISARCH; + + gras_msg_ctx_mallocator = + xbt_mallocator_new(1000, + gras_msg_ctx_mallocator_new_f, + gras_msg_ctx_mallocator_free_f, + gras_msg_ctx_mallocator_reset_f); } /* @@ -88,6 +94,8 @@ void gras_msg_exit(void) { VERB0("Exiting Msg"); xbt_set_free(&_gras_msgtype_set); + + xbt_mallocator_free(gras_msg_ctx_mallocator); } /*