From: Brad Fitzpatrick Date: Fri, 29 Jan 2016 17:45:23 +0000 (+0000) Subject: os: document that FindProcess always succeeds on Unix X-Git-Tag: go1.6rc2~3^2~4 X-Git-Url: http://www.git.cypherpunks.su/?a=commitdiff_plain;h=af15beeab5ff9cde411c3db086ca9a24ace4c898;p=gostls13.git os: document that FindProcess always succeeds on Unix Fixes #14146 Change-Id: I892ca4ccdc1ba785750e1eae800852dc5825156c Reviewed-on: https://go-review.googlesource.com/19093 Reviewed-by: Russ Cox Run-TryBot: Brad Fitzpatrick --- diff --git a/src/os/doc.go b/src/os/doc.go index 389a8eb14c..869a28a8a4 100644 --- a/src/os/doc.go +++ b/src/os/doc.go @@ -7,9 +7,13 @@ package os import "time" // FindProcess looks for a running process by its pid. +// // The Process it returns can be used to obtain information // about the underlying operating system process. -func FindProcess(pid int) (p *Process, err error) { +// +// On Unix systems, FindProcess always succeeds and returns a Process +// for the given pid, regardless of whether the process exists. +func FindProcess(pid int) (*Process, error) { return findProcess(pid) }