X-Git-Url: http://info.iut-bm.univ-fcomte.fr/pub/gitweb/simgrid.git/blobdiff_plain/a56afec84c545bff8857ec1ebc33a0db038aad37..f12b085d941522c6c45e47db742a7fdfedb832da:/src/instr/instr_paje_types.cpp diff --git a/src/instr/instr_paje_types.cpp b/src/instr/instr_paje_types.cpp index 50df5282eb..333e8062cb 100644 --- a/src/instr/instr_paje_types.cpp +++ b/src/instr/instr_paje_types.cpp @@ -10,16 +10,11 @@ XBT_LOG_NEW_DEFAULT_SUBCATEGORY (instr_paje_types, instr, "Paje tracing event sy static type_t rootType = nullptr; /* the root type */ -void PJ_type_alloc () -{ -} - void PJ_type_release () { rootType = nullptr; } - type_t PJ_type_get_root () { return rootType; @@ -56,7 +51,11 @@ void PJ_type_free (type_t type) char *value_name; xbt_dict_cursor_t cursor = nullptr; xbt_dict_foreach(type->values, cursor, value_name, value) { - PJ_value_free (value); + XBT_DEBUG("free value %s, child of %s", value->name, value->father->name); + xbt_free(value->name); + xbt_free(value->color); + xbt_free(value->id); + xbt_free(value); } xbt_dict_free (&type->values); xbt_free (type->name); @@ -67,7 +66,7 @@ void PJ_type_free (type_t type) type = nullptr; } -static void recursiveDestroyType (type_t type) +void recursiveDestroyType (type_t type) { XBT_DEBUG("recursiveDestroyType %s", type->name); xbt_dict_cursor_t cursor = nullptr; @@ -79,12 +78,6 @@ static void recursiveDestroyType (type_t type) PJ_type_free(type); } -void PJ_type_free_all () -{ - recursiveDestroyType (PJ_type_get_root()); - rootType = nullptr; -} - type_t PJ_type_get (const char *name, type_t father) { type_t ret = PJ_type_get_or_null (name, father);