]> git.ipfire.org Git - thirdparty/git.git/commit
fsck: check rev-index checksums
authorDerrick Stolee <derrickstolee@github.com>
Mon, 17 Apr 2023 16:21:39 +0000 (16:21 +0000)
committerJunio C Hamano <gitster@pobox.com>
Mon, 17 Apr 2023 21:39:04 +0000 (14:39 -0700)
commitd975fe1fa57d57cfd21a97f96f4a94b99f50f2f4
tree67bcfd01f1d9300f1840f601a10ca5efd5de28e8
parent0d30feef3c55f63f8db1dc1e52071090d16dfaaf
fsck: check rev-index checksums

The previous change added calls to verify_pack_revindex() in
builtin/fsck.c, but the implementation of the method was left empty. Add
the first and most-obvious check to this method: checksum verification.

While here, create a helper method in the test script that makes it easy
to adjust the .rev file and check that 'git fsck' reports the correct
error message.

Signed-off-by: Derrick Stolee <derrickstolee@github.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
pack-revindex.c
t/t5325-reverse-index.sh