From 65dd06b7acff7ad14ec40c8616597426c49bc48d Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Sat, 17 Oct 2026 12:53:14 -1000 Subject: Hold object sizes in size_t as git 2.55 does Git 2.55 moved object sizes from unsigned long to size_t. The two are the same type on 64-bit hosts, but not on a 32-bit one, where GCC 14 rejects the mismatched pointers, so cgit stopped compiling there. --- source/ui-blob.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'source/ui-blob.c') diff --git a/source/ui-blob.c b/source/ui-blob.c index f7047c7..1d22483 100644 --- a/source/ui-blob.c +++ b/source/ui-blob.c @@ -98,7 +98,7 @@ static int find_path_oid(struct object_id *oid, char *path, int file_only) int cgit_ref_path_exists(const char *path, const char *ref, int file_only) { struct object_id oid; - unsigned long size; + size_t size; char *path_copy = xstrdup(path); int found = 0; @@ -117,7 +117,7 @@ int cgit_print_file(char *path, const char *head, int file_only, int html_escape { struct object_id oid; enum object_type type; - unsigned long size; + size_t size; char *buf; if (repo_get_oid(the_repository, head, &oid)) @@ -165,7 +165,7 @@ void cgit_print_blob(const char *hex, char *path, const char *head, int file_onl { struct object_id oid; enum object_type type; - unsigned long size; + size_t size; char *buf; if (hex) { -- cgit