1 // Copyright 2015 The Go Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style
3 // license that can be found in the LICENSE file.
5 //go:build !plan9 && !windows
15 skipStdinCopyError
= func(err error
) bool {
16 // Ignore EPIPE errors copying to stdin if the program
17 // completed successfully otherwise.
19 pe
, ok
:= err
.(*fs
.PathError
)
21 pe
.Op
== "write" && pe
.Path
== "|1" &&
22 pe
.Err
== syscall
.EPIPE