Merge pull request #4003 from libgit2/cmn/tree-updater-ordering Use the sorted input in the tree updater