mirror of
https://github.com/restic/restic.git
synced 2025-12-04 00:01:48 +00:00
index: Allow inlining of HAT
This commit is contained in:
@@ -1,7 +1,6 @@
|
|||||||
package index
|
package index
|
||||||
|
|
||||||
import (
|
import (
|
||||||
"fmt"
|
|
||||||
"hash/maphash"
|
"hash/maphash"
|
||||||
|
|
||||||
"github.com/restic/restic/internal/restic"
|
"github.com/restic/restic/internal/restic"
|
||||||
@@ -197,7 +196,7 @@ func (h *hashedArrayTree) index(pos uint) (idx uint, subIdx uint) {
|
|||||||
|
|
||||||
func (h *hashedArrayTree) Ref(pos uint) *indexEntry {
|
func (h *hashedArrayTree) Ref(pos uint) *indexEntry {
|
||||||
if pos >= h.size {
|
if pos >= h.size {
|
||||||
panic(fmt.Sprintf("array index %d out of bounds %d", pos, h.size))
|
panic("array index out of bounds")
|
||||||
}
|
}
|
||||||
|
|
||||||
idx, subIdx := h.index(pos)
|
idx, subIdx := h.index(pos)
|
||||||
|
|||||||
Reference in New Issue
Block a user