- Sort Score
- Result 10 results
- Languages All
Results 1 - 4 of 4 for newHandleProcess (0.16 sec)
-
src/os/exec_posix.go
if runtime.GOOS != "windows" { var ok bool h, ok = getPidfd(sysattr.Sys) if !ok { return newPIDProcess(pid), nil } } return newHandleProcess(pid, h), nil } func (p *Process) kill() error { return p.Signal(Kill) } // ProcessState stores information about a process, as reported by Wait. type ProcessState struct {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 10 22:06:47 UTC 2024 - 3.7K bytes - Viewed (0) -
src/os/exec_unix.go
} else if err != nil { // Ignore other errors from pidfdFind, as the callers // do not expect them. Fall back to using the PID. return newPIDProcess(pid), nil } // Use the handle. return newHandleProcess(pid, h), nil } func (p *ProcessState) userTime() time.Duration { return time.Duration(p.rusage.Utime.Nano()) * time.Nanosecond } func (p *ProcessState) systemTime() time.Duration {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 10 22:06:47 UTC 2024 - 4.1K bytes - Viewed (0) -
src/os/exec_windows.go
syscall.PROCESS_QUERY_INFORMATION | syscall.SYNCHRONIZE h, e := syscall.OpenProcess(da, false, uint32(pid)) if e != nil { return nil, NewSyscallError("OpenProcess", e) } return newHandleProcess(pid, uintptr(h)), nil } func init() { cmd := windows.UTF16PtrToString(syscall.GetCommandLine()) if len(cmd) == 0 { arg0, _ := Executable() Args = []string{arg0} } else {
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 10 22:06:47 UTC 2024 - 5K bytes - Viewed (0) -
src/os/exec.go
handle uintptr } func newPIDProcess(pid int) *Process { p := &Process{ Pid: pid, mode: modePID, } runtime.SetFinalizer(p, (*Process).Release) return p } func newHandleProcess(pid int, handle uintptr) *Process { p := &Process{ Pid: pid, mode: modeHandle, handle: handle, } p.state.Store(1) // 1 persistent reference runtime.SetFinalizer(p, (*Process).Release)
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Mon Jun 10 22:06:47 UTC 2024 - 12.8K bytes - Viewed (0)