summaryrefslogtreecommitdiff
path: root/diff-tree.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-20 16:11:46 (GMT)
committerLinus Torvalds <torvalds@ppc970.osdl.org>2005-05-20 16:11:46 (GMT)
commite46091d5f3da713cd3c141ce0bfcd805c6d0ddf8 (patch)
tree0fa1459dec8dcef0dcf174b7077aa0faa16f6031 /diff-tree.c
parent958ba6c96eb58b359c855c9d07e3e45072f0503e (diff)
downloadgit-e46091d5f3da713cd3c141ce0bfcd805c6d0ddf8.zip
git-e46091d5f3da713cd3c141ce0bfcd805c6d0ddf8.tar.gz
git-e46091d5f3da713cd3c141ce0bfcd805c6d0ddf8.tar.bz2
diff-tree: use new base_name_compare() helper function
This fixes diff-tree sorting of directories vs files (we used to use just the regular cache_name_compare() which only works on full file pathnames).
Diffstat (limited to 'diff-tree.c')
-rw-r--r--diff-tree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/diff-tree.c b/diff-tree.c
index 5559dd3..3bf8899 100644
--- a/diff-tree.c
+++ b/diff-tree.c
@@ -107,7 +107,7 @@ static int compare_tree_entry(void *tree1, unsigned long size1, void *tree2, uns
pathlen1 = strlen(path1);
pathlen2 = strlen(path2);
- cmp = cache_name_compare(path1, pathlen1, path2, pathlen2);
+ cmp = base_name_compare(path1, pathlen1, mode1, path2, pathlen2, mode2);
if (cmp < 0) {
show_file("-", tree1, size1, base);
return -1;