aboutsummaryrefslogtreecommitdiffstats
path: root/ui-blob.c
diff options
context:
space:
mode:
authorFlorian Pritz <bluewind@xinu.at>2020-01-17 15:26:09 +0100
committerFlorian Pritz <bluewind@xinu.at>2020-01-17 15:26:09 +0100
commit6c66430e9658616e118d10af9c9ab48858a04e67 (patch)
tree2e83a411ed158f151df085c7f3836827753aecf7 /ui-blob.c
parent42f8840323a219d3eca59a7a2a388c3a28eeb8fb (diff)
parentfa146ccabdd0de746a7076f0630af550e43d9088 (diff)
downloadcgit-6c66430e9658616e118d10af9c9ab48858a04e67.tar.gz
cgit-6c66430e9658616e118d10af9c9ab48858a04e67.tar.xz
Merge tag 'v1.2.2' into local
CGIT v1.2.2
Diffstat (limited to 'ui-blob.c')
-rw-r--r--ui-blob.c13
1 files changed, 8 insertions, 5 deletions
diff --git a/ui-blob.c b/ui-blob.c
index 7b6da2a..30e2d4b 100644
--- a/ui-blob.c
+++ b/ui-blob.c
@@ -56,7 +56,8 @@ int cgit_ref_path_exists(const char *path, const char *ref, int file_only)
goto done;
if (oid_object_info(the_repository, &oid, &size) != OBJ_COMMIT)
goto done;
- read_tree_recursive(lookup_commit_reference(&oid)->maybe_tree, "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
+ read_tree_recursive(the_repository, lookup_commit_reference(the_repository, &oid)->maybe_tree,
+ "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
done:
free(path_items.match);
@@ -89,8 +90,9 @@ int cgit_print_file(char *path, const char *head, int file_only)
return -1;
type = oid_object_info(the_repository, &oid, &size);
if (type == OBJ_COMMIT) {
- commit = lookup_commit_reference(&oid);
- read_tree_recursive(commit->maybe_tree, "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
+ commit = lookup_commit_reference(the_repository, &oid);
+ read_tree_recursive(the_repository, commit->maybe_tree,
+ "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
if (!walk_tree_ctx.found_path)
return -1;
type = oid_object_info(the_repository, &oid, &size);
@@ -145,8 +147,9 @@ void cgit_print_blob(const char *hex, char *path, const char *head, int file_onl
type = oid_object_info(the_repository, &oid, &size);
if ((!hex) && type == OBJ_COMMIT && path) {
- commit = lookup_commit_reference(&oid);
- read_tree_recursive(commit->maybe_tree, "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
+ commit = lookup_commit_reference(the_repository, &oid);
+ read_tree_recursive(the_repository, commit->maybe_tree,
+ "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
type = oid_object_info(the_repository, &oid, &size);
}