diff --git a/rtmp/rtmp.go b/rtmp/rtmp.go index 8a8c7bb7..f1ca4894 100644 --- a/rtmp/rtmp.go +++ b/rtmp/rtmp.go @@ -1669,12 +1669,12 @@ func C_RTMP_SendPacket(r *C_RTMP, packet *C_RTMPPacket, queue int) (ok bool) { // void RTMP_Close(RTMP *r); // rtmp.c +4168 func C_RTMP_Close(r *C_RTMP) { - C_CloseInternal(r, 0) + C_CloseInternal(r, false) } // static void CloseInternal(RTMP *r, int reconnect); // rtmp.c +4175 -func C_CloseInternal(r *C_RTMP, reconnect int32) { +func C_CloseInternal(r *C_RTMP, reconnect bool) { var i int32 if C_RTMP_IsConnected(r) != 0 { @@ -1719,12 +1719,12 @@ func C_CloseInternal(r *C_RTMP, reconnect int32) { r.m_resplen = 0 r.m_unackd = 0 - if ((r.Link.lFlags & RTMP_LF_FTCU) != 0) && (reconnect == 0) { + if ((r.Link.lFlags & RTMP_LF_FTCU) != 0) && !reconnect { r.Link.app = "" r.Link.lFlags ^= RTMP_LF_FAPU } - if reconnect == 0 { + if !reconnect { r.Link.playpath0 = "" } }