aboutsummaryrefslogtreecommitdiffstats
path: root/fsck-cache.c
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@g5.osdl.org>2005-07-07 17:05:41 -0700
committerLinus Torvalds <torvalds@g5.osdl.org>2005-07-07 17:05:41 -0700
commit659cacf5a9a2c7e0eed982e4684f84b47a3e2951 (patch)
treeda221d997e7dd0b15a0b8c5932896221ec74be3b /fsck-cache.c
parente27a56a676a1524036add6067948c647d3093ce8 (diff)
downloadgit-659cacf5a9a2c7e0eed982e4684f84b47a3e2951.tar.gz
git-fsck-cache: don't complain about lacking references when they are all in packs.
We used to not count them at all, which then made us complain that there were no refs.
Diffstat (limited to 'fsck-cache.c')
-rw-r--r--fsck-cache.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/fsck-cache.c b/fsck-cache.c
index e42264e6ce..48be6553a3 100644
--- a/fsck-cache.c
+++ b/fsck-cache.c
@@ -312,8 +312,10 @@ static int fsck_handle_ref(const char *refname, const unsigned char *sha1)
obj = lookup_object(sha1);
if (!obj) {
- if (!standalone && has_sha1_file(sha1))
+ if (!standalone && has_sha1_file(sha1)) {
+ default_refs++;
return 0; /* it is in a pack */
+ }
error("%s: invalid sha1 pointer %s", refname, sha1_to_hex(sha1));
/* We'll continue with the rest despite the error.. */
return 0;