diff options
author | Ian Lance Taylor <ian@gcc.gnu.org> | 2012-01-25 21:54:22 +0000 |
---|---|---|
committer | Ian Lance Taylor <ian@gcc.gnu.org> | 2012-01-25 21:54:22 +0000 |
commit | af92e385667da3fc91ac7f9f0867a56c111110b8 (patch) | |
tree | c8e8990a2197e33f6fe50a28a16714aafe982102 /libgo/go/os/exec_windows.go | |
parent | df1304ee03f41aed179545d1e8b4684cfd22bbdf (diff) | |
download | gcc-af92e385667da3fc91ac7f9f0867a56c111110b8.zip gcc-af92e385667da3fc91ac7f9f0867a56c111110b8.tar.gz gcc-af92e385667da3fc91ac7f9f0867a56c111110b8.tar.bz2 |
libgo: Update to weekly.2012-01-20.
From-SVN: r183540
Diffstat (limited to 'libgo/go/os/exec_windows.go')
-rw-r--r-- | libgo/go/os/exec_windows.go | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/libgo/go/os/exec_windows.go b/libgo/go/os/exec_windows.go index c4c9dcf..7eb7d19 100644 --- a/libgo/go/os/exec_windows.go +++ b/libgo/go/os/exec_windows.go @@ -11,6 +11,8 @@ import ( "unsafe" ) +// Wait waits for the Process to exit or stop, and then returns a +// Waitmsg describing its status and an error, if any. func (p *Process) Wait(options int) (w *Waitmsg, err error) { s, e := syscall.WaitForSingleObject(syscall.Handle(p.handle), syscall.INFINITE) switch s { @@ -43,6 +45,7 @@ func (p *Process) Signal(sig Signal) error { return syscall.Errno(syscall.EWINDOWS) } +// Release releases any resources associated with the Process. func (p *Process) Release() error { if p.handle == -1 { return EINVAL @@ -57,7 +60,7 @@ func (p *Process) Release() error { return nil } -func FindProcess(pid int) (p *Process, err error) { +func findProcess(pid int) (p *Process, err error) { const da = syscall.STANDARD_RIGHTS_READ | syscall.PROCESS_QUERY_INFORMATION | syscall.SYNCHRONIZE h, e := syscall.OpenProcess(da, false, uint32(pid)) |