a new function NoCompression() is added to provide a way to create
uncompressed zstd:chunked files.
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
It is only used internally, and this avoids a warning
about a conflict with io.ByteReader.
Should not change behavior.
Signed-off-by: Miloslav Trmač <mitr@redhat.com>
Go 1.18's testing package is adamant that it doesn't support the %w
specifier for wrapping errors, which makes sense because it outputs
text rather than producing an error object like fmt.Errorf() does.
Change attempts to use %w to %v.
Signed-off-by: Nalin Dahyabhai <nalin@redhat.com>
automatically detect holes in sparse files (the threshold is hardcoded
at 1kb for now) and add this information to the manifest file.
The receiver will create a hole (using unix.Seek and unix.Ftruncate)
instead of writing the actual zeros.
Closes: https://github.com/containers/storage/issues/1091
Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>