Modified genericAddRedBlackTree() and _genericAddRedBlackTree()