GetProcessImageFileName is a wrapper for the same WIN32 API function https://docs.microsoft.com/fr-fr/windows/win32/api/psapi/nf-psapi-getprocessimagefilenamea?redirectedfrom=MSDN
(hProcess windows.Handle, nSize uintptr)
| 87 | // GetProcessImageFileName is a wrapper for the same WIN32 API function |
| 88 | // https://docs.microsoft.com/fr-fr/windows/win32/api/psapi/nf-psapi-getprocessimagefilenamea?redirectedfrom=MSDN |
| 89 | func GetProcessImageFileName(hProcess windows.Handle, nSize uintptr) (data []byte, err error) { |
| 90 | data = make([]byte, nSize) |
| 91 | ret, _, err := syscall.Syscall(procGetProcessImageFileName.Addr(), 3, uintptr(hProcess), uintptr(unsafe.Pointer(&data[0])), nSize) |
| 92 | if ret == 0 { |
| 93 | return nil, err |
| 94 | } |
| 95 | |
| 96 | return data, nil |
| 97 | } |
| 98 | |
| 99 | // EnumProcessModules is a wrapper for the same WIN32 API function |
| 100 | // https://docs.microsoft.com/fr-fr/windows/win32/api/psapi/nf-psapi-enumprocessmodules?redirectedfrom=MSDN |
no outgoing calls
no test coverage detected