Replies: 1 comment 2 replies
-
On Unix you'd use Dlsym and then dereference the pointer. On windows you'd use GetProcAddress. https://pkg.go.dev/github.com/ebitengine/purego?GOOS=darwin#Dlsym |
Beta Was this translation helpful? Give feedback.
2 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Hi,
I have a DLL which export a pointer, this pointer points to a function I need to call, at first I tried with
But obviously this way I was calling the pointer itself rather than what this one is pointing to
then I tried
But RegisterFunctionLib doesn't allow me register something to a uintptr handle it expect a function pointer and
fnc
is declared as uintptrNow I'm trying
But I'm crashing I haven't yet analyzed the crash but I suspect that
uintptr(unsafe.Pointer(&fnc))
is not returning what I want.How am I supposed to do this?
Beta Was this translation helpful? Give feedback.
All reactions