mirror of https://github.com/ceph/go-ceph
c8f26a841b
Although it seems to be stable with the current Go versions, unsafe.Pointers that are created by applying arithmetic on nil pointers are explicitly not allowed[1], and could potentially lead to panics by the garbage collector. To be on the safe side, this change goes back to minimal inline wrappers for the callback registrations, which should be zero-cost. For the callbacks themselves fortunately no wrappers are required, because CGo happily converts void* to uintptr arguments. The potentially problematic VoidPtr helper is removed again. [1] https://golang.org/pkg/unsafe/#Pointer Signed-off-by: Sven Anderson <sven@redhat.com> |
||
---|---|---|
.. | ||
command_input.go | ||
command_input_test.go | ||
command_output.go | ||
command_output_test.go | ||
iovec.go | ||
iovec_test.go | ||
splitbuf.go | ||
splitbuf_test.go | ||
type_aliases.go |