[Opalvoip-svn] SF.net SVN: opalvoip:[33599] opal/trunk/src/sdp/sdp.cxx
Brought to you by:
csoutheren,
rjongbloed
From: <rjo...@us...> - 2015-05-14 12:04:19
|
Revision: 33599 http://sourceforge.net/p/opalvoip/code/33599 Author: rjongbloed Date: 2015-05-14 12:04:16 +0000 (Thu, 14 May 2015) Log Message: ----------- Fixed replacing old SSRC with one from SDP if cname is different. Modified Paths: -------------- opal/trunk/src/sdp/sdp.cxx Modified: opal/trunk/src/sdp/sdp.cxx =================================================================== --- opal/trunk/src/sdp/sdp.cxx 2015-05-13 00:14:50 UTC (rev 33598) +++ opal/trunk/src/sdp/sdp.cxx 2015-05-14 12:04:16 UTC (rev 33599) @@ -1955,10 +1955,16 @@ for (SsrcInfo::const_iterator it = m_ssrcInfo.begin(); it != m_ssrcInfo.end(); ++it) { RTP_SyncSourceId ssrc = it->first; PString cname(it->second.GetString("cname")); - if (!cname.IsEmpty() && rtpSession->AddSyncSource(ssrc, OpalRTPSession::e_Receiver, cname) == ssrc) { - rtpSession->SetAnySyncSource(false); + if (!cname.IsEmpty()) { + if (rtpSession->GetCanonicalName(ssrc, OpalRTPSession::e_Receiver) != cname) { + rtpSession->RemoveSyncSource(ssrc); + PTRACE(4, "Session " << session->GetSessionID() << ", removed receiver SSRC " << RTP_TRACE_SRC(ssrc)); + } + if (rtpSession->AddSyncSource(ssrc, OpalRTPSession::e_Receiver, cname) == ssrc) { + rtpSession->SetAnySyncSource(false); + PTRACE(4, "Session " << session->GetSessionID() << ", added receiver SSRC " << RTP_TRACE_SRC(ssrc)); + } rtpSession->SetMediaStreamId(it->second.GetString("mslabel"), ssrc, OpalRTPSession::e_Receiver); - PTRACE(4, "Session " << session->GetSessionID() << ", added receiver SSRC " << RTP_TRACE_SRC(ssrc)); } } } This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |