rbtree: fix bug in delete fixup causing page fault
This commit is contained in:
parent
ec542bd43e
commit
146e9b775e
1 changed files with 1 additions and 1 deletions
|
|
@ -217,7 +217,7 @@ static void rbt_delete_fixup(struct rbtree *tree, struct rbnode *node)
|
||||||
sibling = node->parent->right;
|
sibling = node->parent->right;
|
||||||
}
|
}
|
||||||
|
|
||||||
if ((!sibling->right || sibling->left->color == RB_BLACK) &&
|
if ((!sibling->left || sibling->left->color == RB_BLACK) &&
|
||||||
(!sibling->right || sibling->right->color == RB_BLACK)) {
|
(!sibling->right || sibling->right->color == RB_BLACK)) {
|
||||||
sibling->color = RB_RED;
|
sibling->color = RB_RED;
|
||||||
node = node->parent;
|
node = node->parent;
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue