版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/jacke121/article/details/88412790
https://stackoverflow.com/questions/35673161/convert-go-byte-to-a-c-char
ok
b := buf.Bytes()
rc := C.the_function(unsafe.Pointer(&b[0]), C.int(buf.Len()))
https://stackoverflow.com/questions/35673161/convert-go-byte-to-a-c-char
ok
b := buf.Bytes()
rc := C.the_function(unsafe.Pointer(&b[0]), C.int(buf.Len()))