Fix TreeWalk to correctly handle missing subtrees
When we are walking through a pair of trees and one of the two trees has
added a new subtree in the middle we need to make sure we use the special
EmptyTreeIterator as a placeholder for the other tree which is missing
that path entry.
This fixes the issue Robin noticed where pulling up the difference for
"
55e9a699df...
5b07a80cf org.spearce.jgit.test" showed files deleted
by 5b07 when they were not even touched. The addition of a new subtree
("revwalk") by 5b07 is what threw the iteration off, causing the other
tree (55e9's) to enter into the wrong subtree at the wrong time.
Signed-off-by: Shawn O. Pearce <spearce@spearce.org>
Signed-off-by: Robin Rosenberg <robin.rosenberg@dewire.com>