From 1812accaed347769b9ee20df400ba1935c754a96 Mon Sep 17 00:00:00 2001 From: Lucas Schnorr Date: Fri, 20 Jan 2012 15:13:36 +0100 Subject: [PATCH] [trace] function to remove a child from its parent container --- src/instr/instr_paje.c | 11 +++++++++++ src/instr/instr_private.h | 1 + 2 files changed, 12 insertions(+) diff --git a/src/instr/instr_paje.c b/src/instr/instr_paje.c index 8d6cf31aec..4b2c73119c 100644 --- a/src/instr/instr_paje.c +++ b/src/instr/instr_paje.c @@ -310,6 +310,17 @@ type_t getType (const char *name, type_t father) return recursiveGetType (name, father); } +void removeContainerFromParent (container_t child) +{ + container_t parent = child->father; + if (parent){ + XBT_DEBUG("removeChildContainer (%s) FromContainer (%s) ", + child->name, + parent->name); + xbt_dict_remove (parent->children, child->name); + } +} + void destroyContainer (container_t container) { XBT_DEBUG("destroy container %s", container->name); diff --git a/src/instr/instr_private.h b/src/instr/instr_private.h index 896e7dfa41..5888ca723f 100644 --- a/src/instr/instr_private.h +++ b/src/instr/instr_private.h @@ -219,6 +219,7 @@ type_t getStateType (const char *name, type_t father); type_t getType (const char *name, type_t father); val_t getValue (const char *valuename, const char *color, type_t father); val_t getValueByName (const char *valuename, type_t father); +void removeContainerFromParent (container_t child); void destroyContainer (container_t container); void destroyAllContainers (void); -- 2.20.1