From d2956385a9319155928e2d7bc5f9d90eeac5d0a5 Mon Sep 17 00:00:00 2001 From: Jeff King Date: Fri, 16 May 2025 00:49:56 -0400 Subject: oid_object_info(): drop type_name strbuf We provide a mechanism for callers to get the object type as a raw string, rather than an object_type enum. This was in theory useful for returning types that are not representable in the enum, but we consider any such type to be an error, and there are no callers that use the strbuf anymore. Let's drop support to simplify the code a bit. Signed-off-by: Jeff King Signed-off-by: Junio C Hamano --- object-store.c | 2 -- 1 file changed, 2 deletions(-) (limited to 'object-store.c') diff --git a/object-store.c b/object-store.c index b8f6955ea7..216c61dcf2 100644 --- a/object-store.c +++ b/object-store.c @@ -646,8 +646,6 @@ static int do_oid_object_info_extended(struct repository *r, *(oi->disk_sizep) = 0; if (oi->delta_base_oid) oidclr(oi->delta_base_oid, the_repository->hash_algo); - if (oi->type_name) - strbuf_addstr(oi->type_name, type_name(co->type)); if (oi->contentp) *oi->contentp = xmemdupz(co->buf, co->size); oi->whence = OI_CACHED; -- cgit v1.3-5-g9baa