mirror of
https://github.com/containers/skopeo.git
synced 2025-09-22 18:37:21 +00:00
Bump github.com/containers/storage from 1.20.1 to 1.20.2
Bumps [github.com/containers/storage](https://github.com/containers/storage) from 1.20.1 to 1.20.2. - [Release notes](https://github.com/containers/storage/releases) - [Changelog](https://github.com/containers/storage/blob/master/docs/containers-storage-changes.md) - [Commits](https://github.com/containers/storage/compare/v1.20.1...v1.20.2) Signed-off-by: dependabot-preview[bot] <support@dependabot.com> Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
committed by
Daniel J Walsh
parent
c6b488a82c
commit
4eaaf31249
23
vendor/github.com/klauspost/compress/zstd/framedec.go
generated
vendored
23
vendor/github.com/klauspost/compress/zstd/framedec.go
generated
vendored
@@ -40,7 +40,7 @@ type frameDec struct {
|
||||
FrameContentSize uint64
|
||||
frameDone sync.WaitGroup
|
||||
|
||||
DictionaryID uint32
|
||||
DictionaryID *uint32
|
||||
HasCheckSum bool
|
||||
SingleSegment bool
|
||||
|
||||
@@ -142,7 +142,7 @@ func (d *frameDec) reset(br byteBuffer) error {
|
||||
|
||||
// Read Dictionary_ID
|
||||
// https://github.com/facebook/zstd/blob/dev/doc/zstd_compression_format.md#dictionary_id
|
||||
d.DictionaryID = 0
|
||||
d.DictionaryID = nil
|
||||
if size := fhd & 3; size != 0 {
|
||||
if size == 3 {
|
||||
size = 4
|
||||
@@ -154,19 +154,22 @@ func (d *frameDec) reset(br byteBuffer) error {
|
||||
}
|
||||
return io.ErrUnexpectedEOF
|
||||
}
|
||||
var id uint32
|
||||
switch size {
|
||||
case 1:
|
||||
d.DictionaryID = uint32(b[0])
|
||||
id = uint32(b[0])
|
||||
case 2:
|
||||
d.DictionaryID = uint32(b[0]) | (uint32(b[1]) << 8)
|
||||
id = uint32(b[0]) | (uint32(b[1]) << 8)
|
||||
case 4:
|
||||
d.DictionaryID = uint32(b[0]) | (uint32(b[1]) << 8) | (uint32(b[2]) << 16) | (uint32(b[3]) << 24)
|
||||
id = uint32(b[0]) | (uint32(b[1]) << 8) | (uint32(b[2]) << 16) | (uint32(b[3]) << 24)
|
||||
}
|
||||
if debug {
|
||||
println("Dict size", size, "ID:", d.DictionaryID)
|
||||
println("Dict size", size, "ID:", id)
|
||||
}
|
||||
if d.DictionaryID != 0 {
|
||||
return ErrUnknownDictionary
|
||||
if id > 0 {
|
||||
// ID 0 means "sorry, no dictionary anyway".
|
||||
// https://github.com/facebook/zstd/blob/dev/doc/zstd_compression_format.md#dictionary-format
|
||||
d.DictionaryID = &id
|
||||
}
|
||||
}
|
||||
|
||||
@@ -351,8 +354,6 @@ func (d *frameDec) initAsync() {
|
||||
// When the frame has finished decoding the *bufio.Reader
|
||||
// containing the remaining input will be sent on frameDec.frameDone.
|
||||
func (d *frameDec) startDecoder(output chan decodeOutput) {
|
||||
// TODO: Init to dictionary
|
||||
d.history.reset()
|
||||
written := int64(0)
|
||||
|
||||
defer func() {
|
||||
@@ -445,8 +446,6 @@ func (d *frameDec) startDecoder(output chan decodeOutput) {
|
||||
|
||||
// runDecoder will create a sync decoder that will decode a block of data.
|
||||
func (d *frameDec) runDecoder(dst []byte, dec *blockDec) ([]byte, error) {
|
||||
// TODO: Init to dictionary
|
||||
d.history.reset()
|
||||
saved := d.history.b
|
||||
|
||||
// We use the history for output to avoid copying it.
|
||||
|
Reference in New Issue
Block a user