summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOpenShift Merge Robot <openshift-merge-robot@users.noreply.github.com>2022-05-04 13:12:13 -0400
committerGitHub <noreply@github.com>2022-05-04 13:12:13 -0400
commit5c8277d943afdfd62f5713672f389abf2ad8b097 (patch)
tree5eeba83c759732defed57b1724dd9b7f79a43a9f
parentb1e9ea38e5a680afb9294cb8a451311991d94765 (diff)
parent9974c90ccc119002780ddfa8bfce5f881c6c9372 (diff)
downloadpodman-5c8277d943afdfd62f5713672f389abf2ad8b097.tar.gz
podman-5c8277d943afdfd62f5713672f389abf2ad8b097.tar.bz2
podman-5c8277d943afdfd62f5713672f389abf2ad8b097.zip
Merge pull request #14109 from giuseppe/ignore-econnreset
libpod: treat ECONNRESET as EOF
-rw-r--r--libpod/oci_attach_linux.go3
1 files changed, 2 insertions, 1 deletions
diff --git a/libpod/oci_attach_linux.go b/libpod/oci_attach_linux.go
index c6af294d5..06f8f8719 100644
--- a/libpod/oci_attach_linux.go
+++ b/libpod/oci_attach_linux.go
@@ -9,6 +9,7 @@ import (
"net"
"os"
"path/filepath"
+ "syscall"
"github.com/containers/common/pkg/config"
"github.com/containers/podman/v4/libpod/define"
@@ -259,7 +260,7 @@ func redirectResponseToOutputStreams(outputStream, errorStream io.Writer, writeO
}
}
}
- if er == io.EOF {
+ if errors.Is(er, io.EOF) || errors.Is(er, syscall.ECONNRESET) {
break
}
if er != nil {