Skip to content
This repository was archived by the owner on Aug 5, 2021. It is now read-only.

cleanTopDrop can create trees with incorrect depth #15

@cbfiddle

Description

@cbfiddle

cleanTopDrop compares sections of the cutIndex with the length of display nodes, for example:
if ((cutIndex >> 5) == display1.length - 2) {
The problem is that the cutIndex is not masked after shifting, which means that the comparison can fail when it should succeed, causing the newDepth to be too high.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions