mirror of https://github.com/golang/go.git
os: explain ProccessState.Exited() SIGKILL interaction
When a process is forcefully killed (for example, with SIGKILL on unix), its ProccessState.Exited() will return false.
Change-Id: I8cebc8d28f2ba1b687c145f6d941647fc3a10665
GitHub-Last-Rev: 414ae1980f
GitHub-Pull-Request: golang/go#48871
Reviewed-on: https://go-review.googlesource.com/c/go/+/354698
Reviewed-by: Ian Lance Taylor <iant@golang.org>
Trust: Alexander Rakoczy <alex@golang.org>
Run-TryBot: Alexander Rakoczy <alex@golang.org>
TryBot-Result: Go Bot <gobot@golang.org>
This commit is contained in:
parent
b8e4df01dd
commit
53260943ea
|
|
@ -149,6 +149,8 @@ func (p *ProcessState) SystemTime() time.Duration {
|
|||
}
|
||||
|
||||
// Exited reports whether the program has exited.
|
||||
// On Unix systems this reports true if the program exited due to calling exit,
|
||||
// but false if the program terminated due to a signal.
|
||||
func (p *ProcessState) Exited() bool {
|
||||
return p.exited()
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue