Unverified Commit 59e9df3c by Edward Thomson Committed by GitHub

Merge pull request #6583 from libgit2/cmn/midx-unknown-chunk

midx: allow unknown chunk ids in multi-pack index files
parents a237aba6 f576b7dd
......@@ -185,7 +185,8 @@ int git_midx_parse(
chunk_oid_fanout = {0},
chunk_oid_lookup = {0},
chunk_object_offsets = {0},
chunk_object_large_offsets = {0};
chunk_object_large_offsets = {0},
chunk_unknown = {0};
GIT_ASSERT_ARG(idx);
......@@ -264,7 +265,9 @@ int git_midx_parse(
break;
default:
return midx_error("unrecognized chunk ID");
chunk_unknown.offset = last_chunk_offset;
last_chunk = &chunk_unknown;
break;
}
}
last_chunk->length = (size_t)(trailer_offset - last_chunk_offset);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment