MCPcopy Create free account
hub / github.com/codeyourweb/irma / GetModuleFileNameEx

Function GetModuleFileNameEx

w32.go:114–122  ·  view source on GitHub ↗

GetModuleFileNameEx is a wrapper for the same WIN32 API function https://docs.microsoft.com/fr-fr/windows/win32/api/psapi/nf-psapi-getmodulefilenameexa?redirectedfrom=MSDN

(hProcess windows.Handle, hModule syscall.Handle, nSize uintptr)

Source from the content-addressed store, hash-verified

112// GetModuleFileNameEx is a wrapper for the same WIN32 API function
113// https://docs.microsoft.com/fr-fr/windows/win32/api/psapi/nf-psapi-getmodulefilenameexa?redirectedfrom=MSDN
114func GetModuleFileNameEx(hProcess windows.Handle, hModule syscall.Handle, nSize uintptr) (data []byte, err error) {
115 data = make([]byte, nSize)
116 ret, _, _ := syscall.Syscall6(procGetModuleFileNameEx.Addr(), 4, uintptr(hProcess), uintptr(hModule), uintptr(unsafe.Pointer(&data[0])), uintptr(nSize), 0, 0)
117 if ret == 0 {
118 return nil, err
119 }
120
121 return data, nil
122}
123
124// GetModuleInformation is a wrapper for the same WIN32 API function
125// https://docs.microsoft.com/en-us/windows/win32/api/psapi/nf-psapi-getmoduleinformation

Callers 1

GetProcessMemoryFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected