aboutsummaryrefslogtreecommitdiff
path: root/sha1_name.c
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2017-11-06 14:24:27 +0900
committerJunio C Hamano <gitster@pobox.com>2017-11-06 14:24:27 +0900
commite7e456f5007f30997e48dec57a1fc09b6b0f071e (patch)
tree47ce2904980d9e233ea416e5cd05be032946c345 /sha1_name.c
parentf4c214b529336124f8642f1373cd4a549d5e7743 (diff)
parent4f01e5080c4a7eee69da47c958888358e6127584 (diff)
downloadgit-e7e456f5007f30997e48dec57a1fc09b6b0f071e.tar.gz
git-e7e456f5007f30997e48dec57a1fc09b6b0f071e.tar.xz
Merge branch 'bc/object-id'
Conversion from uchar[20] to struct object_id continues. * bc/object-id: (25 commits) refs/files-backend: convert static functions to object_id refs: convert read_raw_ref backends to struct object_id refs: convert peel_object to struct object_id refs: convert resolve_ref_unsafe to struct object_id worktree: convert struct worktree to object_id refs: convert resolve_gitlink_ref to struct object_id Convert remaining callers of resolve_gitlink_ref to object_id sha1_file: convert index_path and index_fd to struct object_id refs: convert reflog_expire parameter to struct object_id refs: convert read_ref_at to struct object_id refs: convert peel_ref to struct object_id builtin/pack-objects: convert to struct object_id pack-bitmap: convert traverse_bitmap_commit_list to object_id refs: convert dwim_log to struct object_id builtin/reflog: convert remaining unsigned char uses to object_id refs: convert dwim_ref and expand_ref to struct object_id refs: convert read_ref and read_ref_full to object_id refs: convert resolve_refdup and refs_resolve_refdup to struct object_id Convert check_connected to use struct object_id refs: update ref transactions to use struct object_id ...
Diffstat (limited to 'sha1_name.c')
-rw-r--r--sha1_name.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/sha1_name.c b/sha1_name.c
index 2d6b48047..f3b53f2c2 100644
--- a/sha1_name.c
+++ b/sha1_name.c
@@ -706,7 +706,7 @@ static int get_oid_basic(const char *str, int len, struct object_id *oid,
if (len == GIT_SHA1_HEXSZ && !get_oid_hex(str, oid)) {
if (warn_ambiguous_refs && warn_on_object_refname_ambiguity) {
- refs_found = dwim_ref(str, len, tmp_oid.hash, &real_ref);
+ refs_found = dwim_ref(str, len, &tmp_oid, &real_ref);
if (refs_found > 0) {
warning(warn_msg, len, str);
if (advice_object_name_warning)
@@ -757,11 +757,11 @@ static int get_oid_basic(const char *str, int len, struct object_id *oid,
if (!len && reflog_len)
/* allow "@{...}" to mean the current branch reflog */
- refs_found = dwim_ref("HEAD", 4, oid->hash, &real_ref);
+ refs_found = dwim_ref("HEAD", 4, oid, &real_ref);
else if (reflog_len)
- refs_found = dwim_log(str, len, oid->hash, &real_ref);
+ refs_found = dwim_log(str, len, oid, &real_ref);
else
- refs_found = dwim_ref(str, len, oid->hash, &real_ref);
+ refs_found = dwim_ref(str, len, oid, &real_ref);
if (!refs_found)
return -1;
@@ -800,7 +800,7 @@ static int get_oid_basic(const char *str, int len, struct object_id *oid,
return -1;
}
}
- if (read_ref_at(real_ref, flags, at_time, nth, oid->hash, NULL,
+ if (read_ref_at(real_ref, flags, at_time, nth, oid, NULL,
&co_time, &co_tz, &co_cnt)) {
if (!len) {
if (starts_with(real_ref, "refs/heads/")) {