summaryrefslogtreecommitdiff
path: root/diff-lib.c
diff options
context:
space:
mode:
authorLibravatar Brandon Williams <bmwill@google.com>2017-05-30 10:30:49 -0700
committerLibravatar Junio C Hamano <gitster@pobox.com>2017-06-02 09:36:07 +0900
commit94a0097a41f09e00322add6d1cf62b3610b6a85c (patch)
treede07985882df981e5b9a5e2306d4f393bdafb09d /diff-lib.c
parentdiff: convert run_diff_files to struct object_id (diff)
downloadtgif-94a0097a41f09e00322add6d1cf62b3610b6a85c.tar.xz
diff: convert diff_change to struct object_id
Convert diff_change to take a struct object_id. In addition convert the function pointer type 'change_fn_t' to also take a struct object_id. Signed-off-by: Brandon Williams <bmwill@google.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff-lib.c')
-rw-r--r--diff-lib.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/diff-lib.c b/diff-lib.c
index c82b07dc1e..1e8215df50 100644
--- a/diff-lib.c
+++ b/diff-lib.c
@@ -236,7 +236,7 @@ int run_diff_files(struct rev_info *revs, unsigned int option)
old_oid = &ce->oid;
new_oid = changed ? &null_oid : &ce->oid;
diff_change(&revs->diffopt, oldmode, newmode,
- old_oid->hash, new_oid->hash,
+ old_oid, new_oid,
!is_null_oid(old_oid),
!is_null_oid(new_oid),
ce->name, 0, dirty_submodule);
@@ -367,7 +367,7 @@ static int show_modified(struct rev_info *revs,
return 0;
diff_change(&revs->diffopt, oldmode, mode,
- old->oid.hash, oid->hash, 1, !is_null_oid(oid),
+ &old->oid, oid, 1, !is_null_oid(oid),
old->name, 0, dirty_submodule);
return 0;
}