projects
/
oweals
/
tinc.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d2b19be
)
Set a node's pointers to zero before trying to insert it into a tree.
author
Guus Sliepen
<guus@tinc-vpn.org>
Mon, 3 Dec 2012 08:02:08 +0000
(09:02 +0100)
committer
Guus Sliepen
<guus@tinc-vpn.org>
Mon, 3 Dec 2012 08:02:08 +0000
(09:02 +0100)
src/splay_tree.c
patch
|
blob
|
history
diff --git
a/src/splay_tree.c
b/src/splay_tree.c
index 07478f2f7ce35fdd2a3e9ecad1954a0344404189..54a46f28f6d56468fdc876e08a759cd0bd3fac6b 100644
(file)
--- a/
src/splay_tree.c
+++ b/
src/splay_tree.c
@@
-398,6
+398,8
@@
splay_node_t *splay_insert_node(splay_tree_t *tree, splay_node_t *node) {
splay_node_t *closest;
int result;
+ node->left = node->right = node->parent = node->next = node->prev = NULL;
+
if(!tree->root)
splay_insert_top(tree, node);
else {