MCPcopy Index your code
hub / github.com/Binject/universal / LoadLibrary

Method LoadLibrary

universal.go:21–30  ·  view source on GitHub ↗

LoadLibrary - loads a library into this process from the given buffer

(name string, image *[]byte)

Source from the content-addressed store, hash-verified

19
20// LoadLibrary - loads a library into this process from the given buffer
21func (l *Loader) LoadLibrary(name string, image *[]byte) (*Library, error) {
22
23 library, err := LoadLibraryImpl(name, image)
24 if err != nil {
25 return nil, err
26 }
27 library.Name = name
28 l.Libraries = append(l.Libraries, library)
29 return library, nil
30}
31
32// FindProc - returns the address of the given function from the given library
33func (l *Loader) FindProc(libname string, funcname string) (uintptr, bool) {

Callers 12

Test_Linux_1Function · 0.95
Test_Linux_2Function · 0.95
Test_Darwin_arm64_1Function · 0.95
Test_Darwin_arm64_2Function · 0.95
Test_Windows_MSVC_1Function · 0.95
Test_Windows_gcc_2Function · 0.95
Test_Windows_gcc_3Function · 0.95
Test_Windows_gcc_4Function · 0.95
Test_Windows_WrongArch_4Function · 0.95
mainFunction · 0.95
mainFunction · 0.95
mainFunction · 0.95

Calls 1

LoadLibraryImplFunction · 0.70

Tested by 9

Test_Linux_1Function · 0.76
Test_Linux_2Function · 0.76
Test_Darwin_arm64_1Function · 0.76
Test_Darwin_arm64_2Function · 0.76
Test_Windows_MSVC_1Function · 0.76
Test_Windows_gcc_2Function · 0.76
Test_Windows_gcc_3Function · 0.76
Test_Windows_gcc_4Function · 0.76
Test_Windows_WrongArch_4Function · 0.76