summaryrefslogtreecommitdiff
path: root/builtin/log.c
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2018-11-18 16:47:56 (GMT)
committerJunio C Hamano <gitster@pobox.com>2018-11-19 01:50:33 (GMT)
commite092073d643b17c82d72cf692fbfaea9c9796f11 (patch)
tree303e6f2f58bf1817a9b0f9365761e86c5bc1053a /builtin/log.c
parent0e94dab5be2fd17cfba634f8a29ba5461d2cbd9e (diff)
downloadgit-e092073d643b17c82d72cf692fbfaea9c9796f11.zip
git-e092073d643b17c82d72cf692fbfaea9c9796f11.tar.gz
git-e092073d643b17c82d72cf692fbfaea9c9796f11.tar.bz2
tree.c: make read_tree*() take 'struct repository *'
These functions call tree_entry_interesting() which will soon require a 'struct index_state *' to be passed in. Instead of just changing the function signature to take an index, update to take a repo instead because these functions do need object database access. Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/log.c')
-rw-r--r--builtin/log.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/builtin/log.c b/builtin/log.c
index 9f2d987..7709f2b 100644
--- a/builtin/log.c
+++ b/builtin/log.c
@@ -641,8 +641,9 @@ int cmd_show(int argc, const char **argv, const char *prefix)
diff_get_color_opt(&rev.diffopt, DIFF_COMMIT),
name,
diff_get_color_opt(&rev.diffopt, DIFF_RESET));
- read_tree_recursive((struct tree *)o, "", 0, 0, &match_all,
- show_tree_object, rev.diffopt.file);
+ read_tree_recursive(the_repository, (struct tree *)o, "",
+ 0, 0, &match_all, show_tree_object,
+ rev.diffopt.file);
rev.shown_one = 1;
break;
case OBJ_COMMIT: