summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: cb6c8ed)
raw | patch | inline | side by side (parent: cb6c8ed)
author | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Wed, 18 May 2005 21:07:42 +0000 (14:07 -0700) | ||
committer | Linus Torvalds <torvalds@ppc970.osdl.org> | |
Wed, 18 May 2005 21:07:42 +0000 (14:07 -0700) |
We still need to check which part of the sub-tree is interesting.
diff-tree.c | patch | blob | history |
diff --git a/diff-tree.c b/diff-tree.c
index 3bc7480944037e1c0964217d35b5f1014e4f43fd..8fb5729363e4d85ff0a88173f05140bab43aa42f 100644 (file)
--- a/diff-tree.c
+++ b/diff-tree.c
}
static void show_file(const char *prefix, void *tree, unsigned long size, const char *base);
-
-/* A whole sub-tree went away or appeared */
-static void show_tree(const char *prefix, void *tree, unsigned long size, const char *base)
-{
- while (size) {
- show_file(prefix, tree, size, base);
- update_tree_entry(&tree, &size);
- }
-}
+static void show_tree(const char *prefix, void *tree, unsigned long size, const char *base);
/* A file entry went away or appeared */
static void show_file(const char *prefix, void *tree, unsigned long size, const char *base)
return 0; /* No matches */
}
+/* A whole sub-tree went away or appeared */
+static void show_tree(const char *prefix, void *tree, unsigned long size, const char *base)
+{
+ while (size) {
+ if (interesting(tree, size, base))
+ show_file(prefix, tree, size, base);
+ update_tree_entry(&tree, &size);
+ }
+}
+
static int diff_tree(void *tree1, unsigned long size1, void *tree2, unsigned long size2, const char *base)
{
while (size1 | size2) {