MCPcopy Create free account
hub / github.com/git/git / get_object_disk_usage

Function get_object_disk_usage

builtin/rev-list.c:127–136  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

125static int human_readable;
126
127static off_t get_object_disk_usage(struct object *obj)
128{
129 off_t size;
130 struct object_info oi = OBJECT_INFO_INIT;
131 oi.disk_sizep = &size;
132 if (odb_read_object_info_extended(the_repository->objects,
133 &obj->oid, &oi, 0) < 0)
134 die(_("unable to get disk usage of %s"), oid_to_hex(&obj->oid));
135 return size;
136}
137
138static void add_missing_object_entry(struct object_id *oid, const char *path,
139 unsigned type)

Callers 2

show_commitFunction · 0.85
show_objectFunction · 0.85

Calls 3

oid_to_hexFunction · 0.85
dieFunction · 0.50

Tested by

no test coverage detected