From 915444ebb07079a8ac029953d2a8e1a1fc29c7d1 Mon Sep 17 00:00:00 2001 From: Patrick Date: Tue, 30 Dec 2025 22:33:31 +0100 Subject: fix --- ui-summary.c | 6 +++--- ui-summary.h | 2 +- ui-tree.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/ui-summary.c b/ui-summary.c index 6725634..00a5dd5 100644 --- a/ui-summary.c +++ b/ui-summary.c @@ -185,7 +185,7 @@ static int get_readme_oid_cb(const struct object_id *oid, struct strbuf *base, strbuf_release(&buffer); for (int i = 0; i < sizeof(readme_names)/sizeof(*readme_names); i++) { - if (match_base && stricmp(pathname, readme_names[i]) == 0) { + if (match_base && strcasecmp(pathname, readme_names[i]) == 0) { *(ctx->oid) = *oid; *(ctx->filename) = xstrdup(pathname); ctx->found = true; @@ -198,7 +198,7 @@ static int get_readme_oid_cb(const struct object_id *oid, struct strbuf *base, return 0; } -bool get_readme_oid(const struct tree *tree, struct pathspec *paths, struct object_id *oid, char **filename) { +bool get_readme_oid(struct tree *tree, struct pathspec *paths, struct object_id *oid, char **filename) { struct get_readme_oid_ctx gro_ctx = (struct get_readme_oid_ctx){ .oid = oid, .filename = filename, @@ -209,7 +209,7 @@ bool get_readme_oid(const struct tree *tree, struct pathspec *paths, struct obje return gro_ctx.found; } -void cgit_print_repo_readme_no_layout(const struct tree *tree, struct pathspec *paths) +void cgit_print_repo_readme_no_layout(struct tree *tree, struct pathspec *paths) { char *filename = NULL; struct object_id readme_oid; diff --git a/ui-summary.h b/ui-summary.h index 29b6c1c..c27358d 100644 --- a/ui-summary.h +++ b/ui-summary.h @@ -3,6 +3,6 @@ extern void cgit_print_summary(void); extern void cgit_print_repo_readme(const char *path); -extern void cgit_print_repo_readme_no_layout(const struct tree *tree, struct pathspec *paths); +extern void cgit_print_repo_readme_no_layout(struct tree *tree, struct pathspec *paths); #endif /* UI_SUMMARY_H */ diff --git a/ui-tree.c b/ui-tree.c index a24151f..b961331 100644 --- a/ui-tree.c +++ b/ui-tree.c @@ -296,7 +296,7 @@ static void ls_head(void) html("\n"); } -static void ls_tail(const struct tree *tree, struct pathspec *paths) +static void ls_tail(struct tree *tree, struct pathspec *paths) { html(""); html("\n"); -- cgit v1.2.3