fsck: use ERROR_MULTI_PACK_INDEX
PATCH 1/1 fsck: use ERROR_MULTI_PACK_INDEX
From: Derrick Stolee <[email protected]>
The multi-pack-index was added to the data verified by git-fsck in ea5ae6c3 "fsck: verify multi-pack-index". This implementation was based on the implementation for verifying the commit-graph, and a copy-paste error kept the ERROR_COMMIT_GRAPH flag as the bit set when an error appears in the multi-pack-index.
Add a new flag, ERROR_MULTI_PACK_INDEX, and use that instead.
---
fsck: use ERROR_MULTI_PACK_INDEX
Here is a clean-up that I forgot to send a while back.
Thanks, -Stolee
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-637%2Fderrickstolee%2Ffsck-midx-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-637/derrickstolee/fsck-midx-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/637
builtin/fsck.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
builtin/fsck.c +2 -1
@@ -49,6 +49,7 @@ static int name_objects;#define ERROR_PACK 04#define ERROR_REFS 010#define ERROR_COMMIT_GRAPH 020 +#define ERROR_MULTI_PACK_INDEX 040static const char *describe_object (const struct object_id *oid) {
@@ -952,7 +953,7 @@ int cmd_fsck(int argc, const char **argv, const char *prefix) midx_argv[2 ] ="--object-dir" ; midx_argv[3 ] = odb->path;if (run_command (&midx_verify)) - errors_found |=ERROR_COMMIT_GRAPH ; + errors_found |=ERROR_MULTI_PACK_INDEX ; } }
base-commit: efcab5b7a3d2ce2ae4bf808b335938098b18d960
Signature · 1 line
gitgitgadget
Quoted 4 lines · Derrick Stolee via GitGitGadget
From: Derrick Stolee <[email protected]>
The multi-pack-index was added to the data verified by git-fsck in
ea5ae6c3"fsck: verify multi-pack-index".
That's 66ec0390 (fsck: verify multi-pack-index, 2018-09-13) that first appeared in v2.20
Quoted 6 lines
This implementation was
based on the implementation for verifying the commit-graph, and a copy-paste error kept theERROR_COMMIT_GRAPHflag as the bit set when an error appears in the multi-pack-index.Add a new flag,
ERROR_MULTI_PACK_INDEX, and use that instead.
Thanks. Will queue.