mirror of
https://github.com/octoleo/restic.git
synced 2024-11-26 14:56:29 +00:00
Preallocate pack entries list
This commit is contained in:
parent
caabc4ec44
commit
cd9b526203
@ -233,6 +233,8 @@ func List(k *crypto.Key, rd io.ReaderAt, size int64) (entries []restic.Blob, err
|
||||
|
||||
hdrRd := bytes.NewReader(buf)
|
||||
|
||||
entries = make([]restic.Blob, 0, uint(n)/entrySize)
|
||||
|
||||
pos := uint(0)
|
||||
for {
|
||||
e := headerEntry{}
|
||||
|
Loading…
Reference in New Issue
Block a user