mirror of
https://github.com/nginx/nginx.git
synced 2026-06-27 20:31:58 +00:00
nginx-0.0.1-2004-01-15-20:51:49 import
This commit is contained in:
parent
b5b0ab9195
commit
b10b0ee130
1 changed files with 15 additions and 2 deletions
|
|
@ -147,8 +147,15 @@ void ngx_rbtree_delete(ngx_rbtree_t **root, ngx_rbtree_t *sentinel,
|
|||
}
|
||||
|
||||
if (subst == *root) {
|
||||
/* it's the last node */
|
||||
*root = sentinel;
|
||||
*root = temp;
|
||||
ngx_rbt_black(temp);
|
||||
|
||||
/* DEBUG stuff */
|
||||
node->left = NULL;
|
||||
node->right = NULL;
|
||||
node->parent = NULL;
|
||||
node->key = 0;
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
@ -197,6 +204,12 @@ void ngx_rbtree_delete(ngx_rbtree_t **root, ngx_rbtree_t *sentinel,
|
|||
if (subst->right != sentinel) {
|
||||
subst->right->parent = subst;
|
||||
}
|
||||
|
||||
/* DEBUG stuff */
|
||||
node->left = NULL;
|
||||
node->right = NULL;
|
||||
node->parent = NULL;
|
||||
node->key = 0;
|
||||
}
|
||||
|
||||
if (is_red) {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue