summaryrefslogtreecommitdiff
path: root/src/os/exec_windows.go
diff options
context:
space:
mode:
Diffstat (limited to 'src/os/exec_windows.go')
-rw-r--r--src/os/exec_windows.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/os/exec_windows.go b/src/os/exec_windows.go
index c4f3d4f85..393393b23 100644
--- a/src/os/exec_windows.go
+++ b/src/os/exec_windows.go
@@ -53,6 +53,9 @@ func terminateProcess(pid, exitcode int) error {
}
func (p *Process) signal(sig Signal) error {
+ if p.handle == uintptr(syscall.InvalidHandle) {
+ return syscall.EINVAL
+ }
if p.done() {
return errors.New("os: process already finished")
}