From 2c6c6ea5fdc66117aefdad1115d997b2dd8621ee Mon Sep 17 00:00:00 2001 From: Rolf Ahrenberg Date: Tue, 6 Feb 2018 22:35:48 +0200 Subject: [PATCH] Fixed transport media change for RTCP. --- socket.c | 2 +- tuner.c | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/socket.c b/socket.c index b51d6ea..2b80989 100644 --- a/socket.c +++ b/socket.c @@ -128,7 +128,7 @@ bool cSatipSocket::OpenMulticast(const int portP, const char *streamAddrP, const void cSatipSocket::Close(void) { - debug1("%s sockerPort=%d", __PRETTY_FUNCTION__, socketPortM); + debug1("%s socketPort=%d", __PRETTY_FUNCTION__, socketPortM); // Check if socket exists if (socketDescM >= 0) { Leave(); diff --git a/tuner.c b/tuner.c index df8aee9..c68a635 100644 --- a/tuner.c +++ b/tuner.c @@ -229,6 +229,8 @@ bool cSatipTuner::Connect(void) // Flush any old content //rtpM.Flush(); //rtcpM.Flush(); + if (useTcp) + debug1("%s Requesting TCP [device %d]", __PRETTY_FUNCTION__, deviceIdM); if (rtspM.Setup(*uri, rtpM.Port(), rtcpM.Port(), useTcp)) { keepAliveM.Set(timeoutM); if (nextServerM.IsValid()) { @@ -401,9 +403,9 @@ void cSatipTuner::SetupTransport(int rtpPortP, int rtcpPortP, const char *stream rtcpM.Close(); if (rtcpPortP >= 0) { if (multicast) - rtcpM.OpenMulticast(rtpPortP, streamAddrP, sourceAddrP); + rtcpM.OpenMulticast(rtcpPortP, streamAddrP, sourceAddrP); else - rtcpM.Open(rtpPortP); + rtcpM.Open(rtcpPortP); cSatipPoller::GetInstance()->Register(rtcpM); } }