Module: sip-router
Branch: kamailio_3.0
Commit: 268c9e7db0fd94c94c5e4d5b28c898620f31a9f4
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=268c9e7…
Author: Marius Zbihlei <marius.zbihlei(a)1and1.ro>
Committer: Marius Zbihlei <marius.zbihlei(a)1and1.ro>
Date: Wed Jun 16 14:11:48 2010 +0300
Always set data payload to NULL, thus avoiding problems when root node had data associated
with it
Credits for the patch go to Henning Westerholt.
(cherry picked from commit f05a578613ca1c9cc15e27cc01c5573e1cf0b888)
---
lib/trie/dtrie.c | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
diff --git a/lib/trie/dtrie.c b/lib/trie/dtrie.c
index 62e0cc9..531340b 100644
--- a/lib/trie/dtrie.c
+++ b/lib/trie/dtrie.c
@@ -87,9 +87,9 @@ void dtrie_delete(struct dtrie_node_t *root, struct dtrie_node_t *node,
if (delete_payload) {
delete_payload(node->data);
- node->data = NULL;
}
-
+ node->data = NULL;
+
if (node != root) {
LM_DBG("free node at %p\n", node);
shm_free(node);