FAQ
I get something similar frequently. You are probably storing an integer in
an unsafe.Pointer.

Some c library writers have decided to return void* but sometimes store an
int in it instead of a normal pointer.
Or even better on Platform A it stores a pointer but on Platform B it
stores an integer but we can't break the API so void*.
If you store that pointer in an unsafe.Pointer the GC will work fine on A
but get angry on B (at least in go1.3).
Since it is opaque it doesn't matter to the c functions if it is a pointer
or id.

Try switching some of your unsafe.Pointers to uintptrs (if you are storing
things in unsafe.Pointers).
Or perhaps inside the go package you are using.

Just a guess, I may be completely wrong ;)

--
You received this message because you are subscribed to the Google Groups "golang-nuts" group.
To unsubscribe from this group and stop receiving emails from it, send an email to golang-nuts+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 5 of 21 | next ›
Discussion Overview
groupgolang-nuts @
categoriesgo
postedDec 1, '14 at 3:54p
activeDec 5, '14 at 11:39p
posts21
users9
websitegolang.org

People

Translate

site design / logo © 2021 Grokbase