diff: pass whole pending entry in blobinfo
commit42f5ba5bb6648c16a3c90a0110fbdb430e590a1b
authorJeff King <peff@peff.net>
Fri, 19 May 2017 12:57:30 +0000 (19 08:57 -0400)
committerJunio C Hamano <gitster@pobox.com>
Wed, 24 May 2017 01:59:27 +0000 (24 10:59 +0900)
tree81ac7210f1b599d88171dd8524ffe47d55247aa3
parent18f1ad76392e60cfaf68c3f1e49a4c91bd415d0d
diff: pass whole pending entry in blobinfo

When diffing blobs directly, git-diff picks the blobs out of
the rev_info's pending array and copies the relevant bits to
a custom "struct blobinfo". But the pending array entry
already has all of this information (and more, which we'll
use in future patches). Let's just pass the original entry
instead.

In practice, these two blobs are probably adjacent in the
revs->pending array, and we could just pass the whole array.
But the current code is careful to pick each blob out
separately and put it into another array, so we'll continue
to do so and make our own array-of-pointers.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/diff.c