mirror of
https://git.proxmox.com/git/libgit2
synced 2025-05-07 20:17:59 +00:00
indexer: save the pack index with the right name
Truncate at the slash; otherwise we get ppack-*.idx filenames.
This commit is contained in:
parent
585a2eb75a
commit
d0ec3fb8f0
@ -164,7 +164,7 @@ static int index_path(git_buf *path, git_indexer *idx)
|
|||||||
GIT_OID_HEXSZ + strlen(suffix) + 1) < GIT_SUCCESS)
|
GIT_OID_HEXSZ + strlen(suffix) + 1) < GIT_SUCCESS)
|
||||||
return GIT_ENOMEM;
|
return GIT_ENOMEM;
|
||||||
|
|
||||||
git_buf_truncate(path, slash + 1);
|
git_buf_truncate(path, slash);
|
||||||
git_buf_puts(path, prefix);
|
git_buf_puts(path, prefix);
|
||||||
git_oid_fmt(path->ptr + path->size, &idx->hash);
|
git_oid_fmt(path->ptr + path->size, &idx->hash);
|
||||||
path->size += GIT_OID_HEXSZ;
|
path->size += GIT_OID_HEXSZ;
|
||||||
|
Loading…
Reference in New Issue
Block a user