Skip to content

Commit

Permalink
os/exec: Update Cmd.Run() docs to reflect correct error return types
Browse files Browse the repository at this point in the history
Change-Id: I3fe92d74ff259abdf5d1fd28cdc822db88aae191
Reviewed-on: https://go-review.googlesource.com/39993
Reviewed-by: Ian Lance Taylor <iant@golang.org>
  • Loading branch information
nkubala authored and ianlancetaylor committed Apr 8, 2017
1 parent fd83d7b commit 3959e07
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/os/exec/exec.go
Expand Up @@ -274,9 +274,8 @@ func (c *Cmd) closeDescriptors(closers []io.Closer) {
// copying stdin, stdout, and stderr, and exits with a zero exit
// status.
//
// If the command fails to run or doesn't complete successfully, the
// error is of type *ExitError. Other error types may be
// returned for I/O problems.
// If the command starts but does not complete successfully, the error is of
// type *ExitError. Other error types may be returned for other situations.
func (c *Cmd) Run() error {
if err := c.Start(); err != nil {
return err
Expand Down

0 comments on commit 3959e07

Please sign in to comment.