summaryrefslogtreecommitdiff
path: root/fsck-objects.c
diff options
context:
space:
mode:
authorLibravatar Junio C Hamano <junkio@cox.net>2006-05-01 22:28:33 -0700
committerLibravatar Junio C Hamano <junkio@cox.net>2006-05-01 22:28:33 -0700
commitf5196dbb25febb15b41ef0e6569aaa1654b8533e (patch)
tree2e9ed75926948ae91032289db8cf5fd4d1717d4d /fsck-objects.c
parentMerge branch 'jc/grep' into next (diff)
parentfsck-objects: mark objects reachable from cache-tree (diff)
downloadtgif-f5196dbb25febb15b41ef0e6569aaa1654b8533e.tar.xz
Merge branch 'jc/cache-tree' into next
* jc/cache-tree: fsck-objects: mark objects reachable from cache-tree cache-tree: replace a sscanf() by two strtol() calls
Diffstat (limited to 'fsck-objects.c')
-rw-r--r--fsck-objects.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/fsck-objects.c b/fsck-objects.c
index cc09143a92..98421aab30 100644
--- a/fsck-objects.c
+++ b/fsck-objects.c
@@ -446,6 +446,8 @@ static int fsck_cache_tree(struct cache_tree *it)
if (0 <= it->entry_count) {
struct object *obj = parse_object(it->sha1);
+ mark_reachable(obj, REACHABLE);
+ obj->used = 1;
if (obj->type != tree_type)
err |= objerror(obj, "non-tree in cache-tree");
}