[PATCH] diff.c: truly honor size_only request for populate_filespec.

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

 



For some reason we did not honor size_only requests when "size cache"
was in use.  They should be independent.

Signed-off-by: Junio C Hamano <junkio@xxxxxxx>
---

 * I think this is a right fix.  When used together with other
   patches, it seems to help reducing the memory footprint a
   bit, but by itself not that much and it seems to have
   slightly negative performance impact.

 diff.c |    3 ---
 1 files changed, 0 insertions(+), 3 deletions(-)

diff --git a/diff.c b/diff.c
index 7bbe759..02c9467 100644
--- a/diff.c
+++ b/diff.c
@@ -1503,9 +1503,6 @@ int diff_populate_filespec(struct diff_filespec *s, int size_only)
 	if (S_ISDIR(s->mode))
 		return -1;
 
-	if (!use_size_cache)
-		size_only = 0;
-
 	if (s->data)
 		return err;
 
-- 
1.5.2.rc1.697.g5086


-
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]