tree: fix compilation on darwin
Merge pull request #642 from lovek323/tree

tree: fix compilation on darwin