diff options
author | Junio C Hamano <gitster@pobox.com> | 2018-05-23 07:38:16 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2018-05-23 07:38:16 +0200 |
commit | fcb6df325468a7ae12949ab80dcd37772b9b1fbf (patch) | |
tree | 7ae13a8a1c4f7b417403b6f7f64f34a9565dbab2 /sha1-name.c | |
parent | Merge branch 'cc/perf-aggregate-unknown-option' (diff) | |
parent | cache.h: allow oid_object_info to handle arbitrary repositories (diff) | |
download | git-fcb6df325468a7ae12949ab80dcd37772b9b1fbf.tar.xz git-fcb6df325468a7ae12949ab80dcd37772b9b1fbf.zip |
Merge branch 'sb/oid-object-info'
The codepath around object-info API has been taught to take the
repository object (which in turn tells the API which object store
the objects are to be located).
* sb/oid-object-info:
cache.h: allow oid_object_info to handle arbitrary repositories
packfile: add repository argument to cache_or_unpack_entry
packfile: add repository argument to unpack_entry
packfile: add repository argument to read_object
packfile: add repository argument to packed_object_info
packfile: add repository argument to packed_to_object_type
packfile: add repository argument to retry_bad_packed_offset
cache.h: add repository argument to oid_object_info
cache.h: add repository argument to oid_object_info_extended
Diffstat (limited to 'sha1-name.c')
-rw-r--r-- | sha1-name.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/sha1-name.c b/sha1-name.c index bd99fd822b..80030b159a 100644 --- a/sha1-name.c +++ b/sha1-name.c @@ -223,7 +223,7 @@ static int finish_object_disambiguation(struct disambiguate_state *ds, static int disambiguate_commit_only(const struct object_id *oid, void *cb_data_unused) { - int kind = oid_object_info(oid, NULL); + int kind = oid_object_info(the_repository, oid, NULL); return kind == OBJ_COMMIT; } @@ -232,7 +232,7 @@ static int disambiguate_committish_only(const struct object_id *oid, void *cb_da struct object *obj; int kind; - kind = oid_object_info(oid, NULL); + kind = oid_object_info(the_repository, oid, NULL); if (kind == OBJ_COMMIT) return 1; if (kind != OBJ_TAG) @@ -247,7 +247,7 @@ static int disambiguate_committish_only(const struct object_id *oid, void *cb_da static int disambiguate_tree_only(const struct object_id *oid, void *cb_data_unused) { - int kind = oid_object_info(oid, NULL); + int kind = oid_object_info(the_repository, oid, NULL); return kind == OBJ_TREE; } @@ -256,7 +256,7 @@ static int disambiguate_treeish_only(const struct object_id *oid, void *cb_data_ struct object *obj; int kind; - kind = oid_object_info(oid, NULL); + kind = oid_object_info(the_repository, oid, NULL); if (kind == OBJ_TREE || kind == OBJ_COMMIT) return 1; if (kind != OBJ_TAG) @@ -271,7 +271,7 @@ static int disambiguate_treeish_only(const struct object_id *oid, void *cb_data_ static int disambiguate_blob_only(const struct object_id *oid, void *cb_data_unused) { - int kind = oid_object_info(oid, NULL); + int kind = oid_object_info(the_repository, oid, NULL); return kind == OBJ_BLOB; } @@ -350,7 +350,7 @@ static int show_ambiguous_object(const struct object_id *oid, void *data) if (ds->fn && !ds->fn(oid, ds->cb_data)) return 0; - type = oid_object_info(oid, NULL); + type = oid_object_info(the_repository, oid, NULL); if (type == OBJ_COMMIT) { struct commit *commit = lookup_commit(oid); if (commit) { |