From 716a33352d60b5f01f2556a8ab1fb3a0fbf25ce1 Mon Sep 17 00:00:00 2001 From: cyoung Date: Mon, 20 Jun 2016 23:50:40 -0400 Subject: [PATCH] goCallback() -> goRTLSDRCallback(). (#18) --- exports.go | 4 ++-- rtlsdr.go | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/exports.go b/exports.go index ba2fcd8..e6ea415 100644 --- a/exports.go +++ b/exports.go @@ -18,8 +18,8 @@ import ( */ import "C" -//export goCallback -func goCallback(p1 *C.uchar, p2 C.uint32_t, _ unsafe.Pointer) { +//export goRTLSDRCallback +func goRTLSDRCallback(p1 *C.uchar, p2 C.uint32_t, _ unsafe.Pointer) { // c buffer to go slice without copying var buf []byte length := int(p2) diff --git a/rtlsdr.go b/rtlsdr.go index e5e29c6..73e5f56 100644 --- a/rtlsdr.go +++ b/rtlsdr.go @@ -30,9 +30,9 @@ import ( #include #endif -extern void goCallback(unsigned char *buf, uint32_t len, void *ctx); +extern void goRTLSDRCallback(unsigned char *buf, uint32_t len, void *ctx); static inline rtlsdr_read_async_cb_t get_go_cb() { - return (rtlsdr_read_async_cb_t)goCallback; + return (rtlsdr_read_async_cb_t)goRTLSDRCallback; } */ import "C"