diff options
author | Patrick Steinhardt <ps@pks.im> | 2025-07-01 14:22:25 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2025-07-01 14:46:37 -0700 |
commit | e989dd96b8aa9b20b0e23d3fa845d0baba1b454a (patch) | |
tree | 8f205f5e7ec243777ec9ca46069575cf77164ecf /diff.c | |
parent | 16cf7494962f20d09dcd8ef20af8962600fafca9 (diff) |
odb: rename `oid_object_info()`
Rename `oid_object_info()` to `odb_read_object_info()` as well as their
`_extended()` variant to match other functions related to the object
database and our modern coding guidelines.
Introduce compatibility wrappers so that any in-flight topics will
continue to compile.
Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff.c')
-rw-r--r-- | diff.c | 18 |
1 files changed, 9 insertions, 9 deletions
@@ -4230,14 +4230,14 @@ int diff_populate_filespec(struct repository *r, info.contentp = &s->data; if (options && options->missing_object_cb) { - if (!oid_object_info_extended(r, &s->oid, &info, - OBJECT_INFO_LOOKUP_REPLACE | - OBJECT_INFO_SKIP_FETCH_OBJECT)) + if (!odb_read_object_info_extended(r->objects, &s->oid, &info, + OBJECT_INFO_LOOKUP_REPLACE | + OBJECT_INFO_SKIP_FETCH_OBJECT)) goto object_read; options->missing_object_cb(options->missing_object_data); } - if (oid_object_info_extended(r, &s->oid, &info, - OBJECT_INFO_LOOKUP_REPLACE)) + if (odb_read_object_info_extended(r->objects, &s->oid, &info, + OBJECT_INFO_LOOKUP_REPLACE)) die("unable to read %s", oid_to_hex(&s->oid)); object_read: @@ -4252,8 +4252,8 @@ object_read: } if (!info.contentp) { info.contentp = &s->data; - if (oid_object_info_extended(r, &s->oid, &info, - OBJECT_INFO_LOOKUP_REPLACE)) + if (odb_read_object_info_extended(r->objects, &s->oid, &info, + OBJECT_INFO_LOOKUP_REPLACE)) die("unable to read %s", oid_to_hex(&s->oid)); } s->should_free = 1; @@ -7019,8 +7019,8 @@ void diff_add_if_missing(struct repository *r, { if (filespec && filespec->oid_valid && !S_ISGITLINK(filespec->mode) && - oid_object_info_extended(r, &filespec->oid, NULL, - OBJECT_INFO_FOR_PREFETCH)) + odb_read_object_info_extended(r->objects, &filespec->oid, NULL, + OBJECT_INFO_FOR_PREFETCH)) oid_array_append(to_fetch, &filespec->oid); } |