elvish/pkg/eval/port_windows.go
Qi Xiao 6ced40733c pkg/eval: Fix EPIPE on Windows.
The syscall package exposes an EPIPE on Windows, but it's not what Windows APIs
return. The error number 232 is what is semantically EPIPE.
2021-06-18 00:45:25 +01:00

11 lines
350 B
Go

package eval
import "syscall"
// Error number 232 is what Windows returns when trying to write on a pipe who
// reader has gone. The syscall package defines an EPIPE on Windows, but that's
// not what Windows API actually returns.
//
// https://docs.microsoft.com/en-us/windows/win32/debug/system-error-codes--0-499-
var epipe = syscall.Errno(232)