From 7cea7c5628b9f314d67cff843a959f3c4335e254 Mon Sep 17 00:00:00 2001 From: saxon Date: Fri, 10 Aug 2018 13:37:35 +0930 Subject: [PATCH] Removed var tmp in C_RTMP_Connect for use in memset size determination, can just use var service created above --- rtmp/rtmp.go | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/rtmp/rtmp.go b/rtmp/rtmp.go index 6975eaed..f2c530f5 100644 --- a/rtmp/rtmp.go +++ b/rtmp/rtmp.go @@ -703,8 +703,7 @@ func C_RTMP_Connect(r *C.RTMP, cp *C.RTMPPacket) int { if r.Link.hostname.av_len == 0 { return 0 } - var tmp C.sockaddr_in - memset((*byte)(unsafe.Pointer(&service)), 0, int(unsafe.Sizeof(tmp))) + memset((*byte)(unsafe.Pointer(&service)), 0, int(unsafe.Sizeof(service))) // TODO: port this service.sin_family = C.AF_INET