From 46208527dc531963aa4ebf2a1d6544f63e0600a2 Mon Sep 17 00:00:00 2001 From: Bryce Kwon Date: Fri, 30 Oct 2026 21:45:41 -0700 Subject: Allocate formatted strings with git's xstrfmt --- source/ui-plain.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'source/ui-plain.c') diff --git a/source/ui-plain.c b/source/ui-plain.c index 5bfc41e..f97b80c 100644 --- a/source/ui-plain.c +++ b/source/ui-plain.c @@ -93,9 +93,9 @@ static void print_object(const struct object_id *oid, const char *path) static char *build_path(const char *base, int baselen, const char *path) { if (path[0]) - return cgit_fmtalloc("%.*s%s/", baselen, base, path); + return xstrfmt("%.*s%s/", baselen, base, path); else - return cgit_fmtalloc("%.*s/", baselen, base); + return xstrfmt("%.*s/", baselen, base); } static void print_dir(const char *base, int baselen, const char *path) -- cgit 2.12.1