INNER CODE UNIT · Go
getByteByAddr
krypton-byte/neonize · goneonize/main.go:66
func getByteByAddr(addr *C.uchar, size C.int) []byte {
return C.GoBytes(unsafe.Pointer(addr), size)
// var result []byte
// for i := 0; i < int(size); i++ {
// value := *(*C.uchar)(unsafe.Pointer(uintptr(unsafe.Pointer(addr)) + uintptr(i)))
// // fmt.Println(value)
// result = append(result, byte(value))
// }
// return result
}
// applyProxySettings configures the proxy on the whatsmeow client.
// It uses C.struct_ProxySettings (defined in header/cstruct.h) directly,
// so the memory layout is guaranteed by the C compiler — no manual
// Go-struct-to-C alignment required.
//
// When settings is nil (Python passes None), the proxy step is skipped.
func applyProxySettings(client *whatsmeow.Client, settings *C.struct_ProxySettings) error {