diff options
| author | Tim Cooper <tim.cooper@layeh.com> | 2018-01-26 22:29:55 -0400 |
|---|---|---|
| committer | Brad Fitzpatrick <bradfitz@golang.org> | 2018-04-17 05:05:45 +0000 |
| commit | 155aefe0c182f3788e44596db5f09cf94d2c6a3e (patch) | |
| tree | 6b27d9146252ba957f361baa71a3fca058f96dc0 /src/os/exec/exec.go | |
| parent | d0925228d7171eb074902a53249bccfbda51abea (diff) | |
| download | go-155aefe0c182f3788e44596db5f09cf94d2c6a3e.tar.xz | |
os/exec: remove "binary" when talking about executables
The use of binary was incorrect as executable files can also be scripts.
The docs for Error are also reworded. The old docs implied that Error was
returned when attempting to start an executable, which is not correct: it
was returned by LookPath when the file was not found or did not have the
attributes of an executable.
Change-Id: I757a44b16612936df4498b43c45c12e4c14956d2
Reviewed-on: https://go-review.googlesource.com/90315
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Diffstat (limited to 'src/os/exec/exec.go')
| -rw-r--r-- | src/os/exec/exec.go | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/src/os/exec/exec.go b/src/os/exec/exec.go index 5ef9540141..41fbf96370 100644 --- a/src/os/exec/exec.go +++ b/src/os/exec/exec.go @@ -34,11 +34,13 @@ import ( "syscall" ) -// Error records the name of a binary that failed to be executed -// and the reason it failed. +// Error is returned by LookPath when it fails to classify a file as an +// executable. type Error struct { + // Name is the file name for which the error occurred. Name string - Err error + // Err is the underlying error. + Err error } func (e *Error) Error() string { |
