diff --git a/rtmp/rtmp.go b/rtmp/rtmp.go index e5ada2d9..2556a58e 100644 --- a/rtmp/rtmp.go +++ b/rtmp/rtmp.go @@ -963,9 +963,9 @@ func sendConnectPacket(r *C.RTMP, cp *C.RTMPPacket) int { //(*C.char)(unsafe.Pointer(pend)), &av_connect))) enc = amfEncodeString(enc, pend, &av_connect) r.m_numInvokes += 1 - enc = (*byte)(unsafe.Pointer(C.AMF_EncodeNumber((*C.char)(unsafe.Pointer(enc)), - (*C.char)(unsafe.Pointer(pend)), C.double(r.m_numInvokes)))) - //enc = amfEncodeNumber(enc, pend, float64(r.m_numInvokes)) + //enc = (*byte)(unsafe.Pointer(C.AMF_EncodeNumber((*C.char)(unsafe.Pointer(enc)), + //(*C.char)(unsafe.Pointer(pend)), C.double(r.m_numInvokes)))) + enc = amfEncodeNumber(enc, pend, float64(r.m_numInvokes)) *indxBytePtr(unsafe.Pointer(enc), 0) = AMF_OBJECT