pdfdir = $(docdir)
mandir = $(prefix)/share/man
SHA1_HEADER = <openssl/sha.h>
-GIT_VER = 2.31.1
+GIT_VER = 2.32.0
GIT_URL = https://www.kernel.org/pub/software/scm/git/git-$(GIT_VER).tar.xz
INSTALL = install
COPYTREE = cp -r
-Subproject commit 48bf2fa8bad054d66bd79c6ba903c89c704201f7
+Subproject commit ebf3c04b262aa27fbb97f8a0156c2347fecafafb
}
static int walk_tree(const struct object_id *oid, struct strbuf *base,
- const char *pathname, unsigned mode, int stage,
- void *cbdata)
+ const char *pathname, unsigned mode, void *cbdata)
{
struct walk_tree_context *walk_tree_ctx = cbdata;
walk_tree_ctx.match_baselen = (path_items.match) ?
basedir_len(path_items.match) : -1;
- read_tree_recursive(the_repository,
- repo_get_commit_tree(the_repository, commit),
- "", 0, 0,
- &paths, walk_tree, &walk_tree_ctx);
+ read_tree(the_repository, repo_get_commit_tree(the_repository, commit),
+ &paths, walk_tree, &walk_tree_ctx);
if (!walk_tree_ctx.state)
cgit_print_error_page(404, "Not found", "Not found");
else if (walk_tree_ctx.state == 2)
};
static int walk_tree(const struct object_id *oid, struct strbuf *base,
- const char *pathname, unsigned mode, int stage, void *cbdata)
+ const char *pathname, unsigned mode, void *cbdata)
{
struct walk_tree_context *walk_tree_ctx = cbdata;
goto done;
if (oid_object_info(the_repository, &oid, &size) != OBJ_COMMIT)
goto done;
- read_tree_recursive(the_repository,
- repo_get_commit_tree(the_repository, lookup_commit_reference(the_repository, &oid)),
- "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
+ read_tree(the_repository,
+ repo_get_commit_tree(the_repository, lookup_commit_reference(the_repository, &oid)),
+ &paths, walk_tree, &walk_tree_ctx);
done:
free(path_items.match);
type = oid_object_info(the_repository, &oid, &size);
if (type == OBJ_COMMIT) {
commit = lookup_commit_reference(the_repository, &oid);
- read_tree_recursive(the_repository,
- repo_get_commit_tree(the_repository, commit),
- "", 0, 0, &paths, walk_tree,
- &walk_tree_ctx);
+ read_tree(the_repository, repo_get_commit_tree(the_repository, commit),
+ &paths, walk_tree, &walk_tree_ctx);
if (!walk_tree_ctx.found_path)
return -1;
type = oid_object_info(the_repository, &oid, &size);
if ((!hex) && type == OBJ_COMMIT && path) {
commit = lookup_commit_reference(the_repository, &oid);
- read_tree_recursive(the_repository,
- repo_get_commit_tree(the_repository, commit),
- "", 0, 0, &paths, walk_tree,
- &walk_tree_ctx);
+ read_tree(the_repository, repo_get_commit_tree(the_repository, commit),
+ &paths, walk_tree, &walk_tree_ctx);
type = oid_object_info(the_repository, &oid, &size);
}
}
static int walk_tree(const struct object_id *oid, struct strbuf *base,
- const char *pathname, unsigned mode, int stage, void *cbdata)
+ const char *pathname, unsigned mode, void *cbdata)
{
struct walk_tree_context *walk_tree_ctx = cbdata;
}
else
walk_tree_ctx.match_baselen = basedir_len(path_items.match);
- read_tree_recursive(the_repository,
- repo_get_commit_tree(the_repository, commit),
- "", 0, 0, &paths, walk_tree, &walk_tree_ctx);
+ read_tree(the_repository, repo_get_commit_tree(the_repository, commit),
+ &paths, walk_tree, &walk_tree_ctx);
if (!walk_tree_ctx.match)
cgit_print_error_page(404, "Not found", "Not found");
else if (walk_tree_ctx.match == 2)
};
static int single_tree_cb(const struct object_id *oid, struct strbuf *base,
- const char *pathname, unsigned mode, int stage,
- void *cbdata)
+ const char *pathname, unsigned mode, void *cbdata)
{
struct single_tree_ctx *ctx = cbdata;
tree_ctx.name = NULL;
tree_ctx.count = 0;
- read_tree_recursive(the_repository, tree, "", 0, 1,
- &paths, single_tree_cb, &tree_ctx);
+ read_tree(the_repository, tree, &paths, single_tree_cb, &tree_ctx);
if (tree_ctx.count != 1)
break;
}
static int ls_item(const struct object_id *oid, struct strbuf *base,
- const char *pathname, unsigned mode, int stage, void *cbdata)
+ const char *pathname, unsigned mode, void *cbdata)
{
struct walk_tree_context *walk_tree_ctx = cbdata;
char *name;
}
ls_head();
- read_tree_recursive(the_repository, tree, "", 0, 1,
- &paths, ls_item, walk_tree_ctx);
+ read_tree(the_repository, tree, &paths, ls_item, walk_tree_ctx);
ls_tail();
}
static int walk_tree(const struct object_id *oid, struct strbuf *base,
- const char *pathname, unsigned mode, int stage, void *cbdata)
+ const char *pathname, unsigned mode, void *cbdata)
{
struct walk_tree_context *walk_tree_ctx = cbdata;
return 0;
}
}
- ls_item(oid, base, pathname, mode, stage, walk_tree_ctx);
+ ls_item(oid, base, pathname, mode, walk_tree_ctx);
return 0;
}
goto cleanup;
}
- read_tree_recursive(the_repository,
- repo_get_commit_tree(the_repository, commit),
- "", 0, 0,
- &paths, walk_tree, &walk_tree_ctx);
+ read_tree(the_repository, repo_get_commit_tree(the_repository, commit),
+ &paths, walk_tree, &walk_tree_ctx);
if (walk_tree_ctx.state == 1)
ls_tail();
else if (walk_tree_ctx.state == 2)