Commit Briefs
fix a bug where 'got revert -R' failed on added subtrees
The command could fail with "got: no such entry found in tree". This problem is reproduced by the regression test added in this commit. This happened because file index entries were processed in the wrong order by diff_fileindex_dir(). To fix this, keep removed entries in the RB tree and skip them when the file index is written out, rather than removing entries from the RB tree immediately causing side-effects for RB_NEXT and friends.
fix a bug where 'got log PATH' failed to map PATH into the repository
The problem occured inside /usr/src/sys due to the /sys symlink, where /usr/src was a got work tree. If a work tree is present we already have the right path so checking the disk is pointless.
create temporary workaround to opening /dev/null during diffing.
this will need to be reworked later. ok stsp
Remove redundant error check after got_object_id_by_path().
An error code is always returned when the oid is NULL.