Skip to content

Commit bf12013

Browse files
chiyutianyigitster
authored andcommitted
pack-objects: fix comment of reused_chunk.difference
As record_reused_object(offset, offset - hashfile_total(out)) said, reused_chunk.difference should be the offset of original packfile minus the offset of the generated packfile. But the comment presented an opposite way. Signed-off-by: Han Xin <[email protected]> Acked-by: Jeff King <[email protected]> Signed-off-by: Junio C Hamano <[email protected]>
1 parent 1424303 commit bf12013

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

builtin/pack-objects.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -815,8 +815,8 @@ static struct reused_chunk {
815815
/* The offset of the first object of this chunk in the original
816816
* packfile. */
817817
off_t original;
818-
/* The offset of the first object of this chunk in the generated
819-
* packfile minus "original". */
818+
/* The difference for "original" minus the offset of the first object of
819+
* this chunk in the generated packfile. */
820820
off_t difference;
821821
} *reused_chunks;
822822
static int reused_chunks_nr;

0 commit comments

Comments
 (0)