Lines Matching full:syscall
11 "syscall"
18 s, e := syscall.WaitForSingleObject(syscall.Handle(handle), syscall.INFINITE)
20 case syscall.WAIT_OBJECT_0:
22 case syscall.WAIT_FAILED:
28 e = syscall.GetExitCodeProcess(syscall.Handle(handle), &ec)
32 var u syscall.Rusage
33 e = syscall.GetProcessTimes(syscall.Handle(handle), &u.CreationTime, &u.ExitTime, &u.KernelTime, &u.UserTime)
44 return &ProcessState{p.Pid, syscall.WaitStatus{ExitCode: ec}, &u}, nil
48 h, e := syscall.OpenProcess(syscall.PROCESS_TERMINATE, false, uint32(pid))
52 defer syscall.CloseHandle(h)
53 e = syscall.TerminateProcess(h, uint32(exitcode))
59 if handle == uintptr(syscall.InvalidHandle) {
60 return syscall.EINVAL
69 return syscall.Errno(syscall.EWINDOWS)
74 if handle == uintptr(syscall.InvalidHandle) {
75 return syscall.EINVAL
77 e := syscall.CloseHandle(syscall.Handle(handle))
81 atomic.StoreUintptr(&p.handle, uintptr(syscall.InvalidHandle))
88 const da = syscall.STANDARD_RIGHTS_READ |
89 syscall.PROCESS_QUERY_INFORMATION | syscall.SYNCHRONIZE
90 h, e := syscall.OpenProcess(da, false, uint32(pid))
99 cmd := syscall.GetCommandLine()
100 argv, e := syscall.CommandLineToArgv(cmd, &argc)
104 defer syscall.LocalFree(syscall.Handle(uintptr(unsafe.Pointer(argv))))
107 Args[i] = string(syscall.UTF16ToString((*v)[:]))
111 func ftToDuration(ft *syscall.Filetime) time.Duration {