From: Junio C Hamano Date: Thu, 25 Jun 2020 18:08:14 GMT Subject: Re: [PATCH v4 1/2] diff-files --raw: show correct post-image of intent-to-add files Message-ID: In-Reply-To: <69256ab9107c3dba0dc007b69cc0ce98a9b91f9a.1593107621.git.gitgitgadget@gmail.com> "Johannes Schindelin via GitGitGadget" writes: > diff --git a/diff-lib.c b/diff-lib.c > index 61812f48c2..25fd2dee19 100644 > --- a/diff-lib.c > +++ b/diff-lib.c > @@ -220,8 +220,7 @@ int run_diff_files(struct rev_info *revs, unsigned int option) > } else if (revs->diffopt.ita_invisible_in_index && > ce_intent_to_add(ce)) { > diff_addremove(&revs->diffopt, '+', ce->ce_mode, > - the_hash_algo->empty_tree, 0, > - ce->name, 0); > + &null_oid, 0, ce->name, 0); This (even if the preimage were correctly using empty_blob) is *so* simple a change that it is very surprising that the new test in [2/2] passes without any other code change. It means that difftool was written correctly in the first place, right? Nicely done.