nginx-0.0.1-2004-01-15-20:51:49 import

This commit is contained in:
Igor Sysoev 2004-01-15 17:51:49 +00:00
parent b5b0ab9195
commit b10b0ee130

View File

@ -147,8 +147,15 @@ void ngx_rbtree_delete(ngx_rbtree_t **root, ngx_rbtree_t *sentinel,
} }
if (subst == *root) { if (subst == *root) {
/* it's the last node */ *root = temp;
*root = sentinel; ngx_rbt_black(temp);
/* DEBUG stuff */
node->left = NULL;
node->right = NULL;
node->parent = NULL;
node->key = 0;
return; return;
} }
@ -197,6 +204,12 @@ void ngx_rbtree_delete(ngx_rbtree_t **root, ngx_rbtree_t *sentinel,
if (subst->right != sentinel) { if (subst->right != sentinel) {
subst->right->parent = subst; subst->right->parent = subst;
} }
/* DEBUG stuff */
node->left = NULL;
node->right = NULL;
node->parent = NULL;
node->key = 0;
} }
if (is_red) { if (is_red) {