Skip to content

Commit 96ab6e0

Browse files
pcloudsgitster
authored andcommitted
list-objects.c: reduce the_repository references
Signed-off-by: Nguyễn Thái Ngọc Duy <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 01d40c8 commit 96ab6e0

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

list-objects.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -123,15 +123,15 @@ static void process_tree_contents(struct traversal_context *ctx,
123123
}
124124

125125
if (S_ISDIR(entry.mode)) {
126-
struct tree *t = lookup_tree(the_repository, entry.oid);
126+
struct tree *t = lookup_tree(ctx->revs->repo, entry.oid);
127127
t->object.flags |= NOT_USER_GIVEN;
128128
process_tree(ctx, t, base, entry.path);
129129
}
130130
else if (S_ISGITLINK(entry.mode))
131131
process_gitlink(ctx, entry.oid->hash,
132132
base, entry.path);
133133
else {
134-
struct blob *b = lookup_blob(the_repository, entry.oid);
134+
struct blob *b = lookup_blob(ctx->revs->repo, entry.oid);
135135
b->object.flags |= NOT_USER_GIVEN;
136136
process_blob(ctx, b, base, entry.path);
137137
}

0 commit comments

Comments
 (0)