[PATCH 17/28] makes diff_cache void

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Makes diff_cache void and cleans up function calls.

		David

Signed-off-by: David Rientjes <rientjes@xxxxxxxxxx>
---
 diff-lib.c |   16 +++++++---------
 1 files changed, 7 insertions(+), 9 deletions(-)

diff --git a/diff-lib.c b/diff-lib.c
index 116b5a9..3c42b09 100644
--- a/diff-lib.c
+++ b/diff-lib.c
@@ -227,10 +227,10 @@ static int show_modified(struct rev_info
 	return 0;
 }
 
-static int diff_cache(struct rev_info *revs,
-		      struct cache_entry **ac, int entries,
-		      const char **pathspec,
-		      int cached, int match_missing)
+static void diff_cache(struct rev_info *revs,
+		       struct cache_entry **ac, int entries,
+		       const char **pathspec,
+		       int cached, int match_missing)
 {
 	while (entries) {
 		struct cache_entry *ce = *ac;
@@ -292,7 +292,6 @@ skip_entry:
 			entries--;
 		} while (entries && ce_same_name(ce, ac[0]));
 	}
-	return 0;
 }
 
 /*
@@ -313,7 +312,6 @@ static void mark_merge_entries(void)
 
 int run_diff_index(struct rev_info *revs, int cached)
 {
-	int ret;
 	struct object *ent;
 	struct tree *tree;
 	const char *tree_name;
@@ -339,9 +337,9 @@ int run_diff_index(struct rev_info *revs
 		return error("bad tree object %s", tree_name);
 	if (read_tree(tree, 1, revs->prune_data))
 		return error("unable to read tree object %s", tree_name);
-	ret = diff_cache(revs, active_cache, active_nr, revs->prune_data,
-			 cached, match_missing);
+	diff_cache(revs, active_cache, active_nr, revs->prune_data,
+		   cached, match_missing);
 	diffcore_std(&revs->diffopt);
 	diff_flush(&revs->diffopt);
-	return ret;
+	return 0;
 }
-- 
1.4.2.g89bb-dirty

-
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]