From 7a35f108c7b12412eb1754842234aa11cab80b0f Mon Sep 17 00:00:00 2001 From: Philipp Hancke Date: Sat, 1 Jul 2023 09:47:34 +0200 Subject: [PATCH] Remove dead code in offer/answer handling MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit the ssrc-group consistency is checked by the media engine. BUG=chromium:1454860 Change-Id: Ib9f60a0e773ffd1810aae4e5f464d12619e94b5c Reviewed-on: https://webrtc-review.googlesource.com/c/src/+/311160 Reviewed-by: Henrik Boström Reviewed-by: Artem Titov Commit-Queue: Philipp Hancke Cr-Commit-Position: refs/heads/main@{#40389} --- pc/sdp_offer_answer.cc | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/pc/sdp_offer_answer.cc b/pc/sdp_offer_answer.cc index 97d01573cf..4874444eae 100644 --- a/pc/sdp_offer_answer.cc +++ b/pc/sdp_offer_answer.cc @@ -491,25 +491,6 @@ RTCError ValidateBundledPayloadTypes( return RTCError::OK(); } -RTCError ValidateSsrcGroups(const cricket::SessionDescription& description) { - // https://www.rfc-editor.org/rfc/rfc5576#section-4.2 - // Every listed in an "ssrc-group" attribute MUST be - // defined by a corresponding "ssrc:" line in the same media - // description. - for (const ContentInfo& content : description.contents()) { - if (!content.media_description()) { - continue; - } - for (const StreamParams& sp : content.media_description()->streams()) { - for (const cricket::SsrcGroup& group : sp.ssrc_groups) { - RTC_LOG(LS_ERROR) << "YO " << group.semantics << " #" - << group.ssrcs.size(); - } - } - } - return RTCError::OK(); -} - RTCError FindDuplicateHeaderExtensionIds( const RtpExtension extension, std::map& id_to_extension) { @@ -3586,11 +3567,6 @@ RTCError SdpOfferAnswerHandler::ValidateSessionDescription( return RTCError(RTCErrorType::INVALID_PARAMETER, kBundleWithoutRtcpMux); } - error = ValidateSsrcGroups(*sdesc->description()); - if (!error.ok()) { - return error; - } - // TODO(skvlad): When the local rtcp-mux policy is Require, reject any // m-lines that do not rtcp-mux enabled.