-
Notifications
You must be signed in to change notification settings - Fork 10
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Go 1.6 - C pointer <-> Go pointer rules change causes crash #10
Comments
I'm not so familiar with the new cgo rules, but I could reproduce the crash. What I think of as a solution is replacing all Which is a problem when it comes to putting data in inputAsCChars, because *C.char is not indexable. Anyway I can't test it right now, I need a HID device first, this afternoon, or tomorrow. |
Still trying to fix it, this fork doesn't crash cgo anymore: https://github.com/vitaminwater/cgo.wchar/ But now the whole iconv thing is broken, output for tests is:
(last test not displayed hangs forever) Still lacking knowledge, if you could provide me with some input I might create a good pull request to fix it. |
The first test says |
Looks like the wchar_t type does not exist on OSX: http://www.firstobject.com/wchar_t-string-on-linux-osx-windows.htm |
Further readings tend to make me think that cgo.wchar could be avoided thanks to golang's Maybe it would be wise to remove cgo.wchar from go.hid ? |
The new rules: https://golang.org/cmd/cgo/#hdr-Passing_pointers
causes a crash in convert.go line 150:
With the trace:
There must be other places in the code causing this crash.
The text was updated successfully, but these errors were encountered: