Open ashwin-git-s opened 4 years ago
This line if code checks only the right child colour. It should check the left child as well.
https://github.com/Bibeknam/algorithmtutorprograms/blob/705130fc0c5fb5c6bdc53967aea7de644e9bb2c5/data-structures/red-black-trees/RedBlackTree.cpp#L115
This fixes a rare segfault during deleteNode (~1 in 10,000 deletions).
Thanks!
This line if code checks only the right child colour. It should check the left child as well.
https://github.com/Bibeknam/algorithmtutorprograms/blob/705130fc0c5fb5c6bdc53967aea7de644e9bb2c5/data-structures/red-black-trees/RedBlackTree.cpp#L115