-
-
Notifications
You must be signed in to change notification settings - Fork 52
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
callback: use handles rather than passing Go pointers
The cgo pointer passing rules forbid passing a Go pointer to C if that pointer points to memory containing other Go pointers. This is true even if the Go pointer is converted to uintptr. This change fixes the code to use a handle instead, and to look up the handle in the callback function.
- Loading branch information
1 parent
0cc1174
commit 8c66b9c
Showing
2 changed files
with
52 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters