commit-reach: make can_all_from_reach... linear
[gitweb.git] / upload-pack.c
index 11c426685d2f2ba7c50d798b6ace6e619a265aed..1e498f1188c90e4998bb06e17f99c4780592a553 100644 (file)
@@ -338,11 +338,14 @@ static int got_oid(const char *hex, struct object_id *oid)
 
 static int ok_to_give_up(void)
 {
+       uint32_t min_generation = GENERATION_NUMBER_ZERO;
+
        if (!have_obj.nr)
                return 0;
 
        return can_all_from_reach_with_flag(&want_obj, THEY_HAVE,
-                                           COMMON_KNOWN, oldest_have);
+                                           COMMON_KNOWN, oldest_have,
+                                           min_generation);
 }
 
 static int get_common_commits(void)