mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-12-21 03:10:25 +08:00
Fix tavl_delete
This commit is contained in:
parent
a727de0367
commit
53833c6ae6
@ -251,10 +251,9 @@ tavl_delete( Avlnode **root, void* data, AVL_CMP fcmp )
|
|||||||
*root = q;
|
*root = q;
|
||||||
}
|
}
|
||||||
/* new parent of p points to p */
|
/* new parent of p points to p */
|
||||||
if ( depth > 2 ) {
|
if ( depth > 1 ) {
|
||||||
r = pptr[depth-2];
|
r = pptr[depth-1];
|
||||||
r->avl_link[1] = p;
|
r->avl_link[1] = p;
|
||||||
pptr[depth-1] = p;
|
|
||||||
} else {
|
} else {
|
||||||
q->avl_link[0] = p;
|
q->avl_link[0] = p;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user