mirror of
https://github.com/containers/podman.git
synced 2025-12-09 15:19:35 +08:00
Vendor in latest containers(common, storage,image, buildah)
Signed-off-by: Daniel J Walsh <dwalsh@redhat.com>
This commit is contained in:
9
vendor/github.com/containers/storage/pkg/archive/filter.go
generated
vendored
9
vendor/github.com/containers/storage/pkg/archive/filter.go
generated
vendored
@@ -46,7 +46,14 @@ func tryProcFilter(args []string, input io.Reader, cleanup func()) (io.ReadClose
|
||||
go func() {
|
||||
err := cmd.Run()
|
||||
if err != nil && stderrBuf.Len() > 0 {
|
||||
err = fmt.Errorf("%s: %w", strings.TrimRight(stderrBuf.String(), "\n"), err)
|
||||
b := make([]byte, 1)
|
||||
// if there is an error reading from input, prefer to return that error
|
||||
_, errRead := input.Read(b)
|
||||
if errRead != nil && errRead != io.EOF {
|
||||
err = errRead
|
||||
} else {
|
||||
err = fmt.Errorf("%s: %w", strings.TrimRight(stderrBuf.String(), "\n"), err)
|
||||
}
|
||||
}
|
||||
w.CloseWithError(err) // CloseWithErr(nil) == Close()
|
||||
cleanup()
|
||||
|
||||
Reference in New Issue
Block a user