From 4fb5c99228ee6dd684e12aa0fe291640b63b077a Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Thu, 24 Aug 2023 11:39:09 -0400 Subject: [PATCH] MT#57719 do lookup based on a=mid in get_media() Change-Id: Ib6afa32ab48898e39a842e4900df81d24db8d704 --- daemon/call.c | 15 +++++++-------- 1 file changed, 7 insertions(+), 8 deletions(-) diff --git a/daemon/call.c b/daemon/call.c index 8f5711441..47e7c37e5 100644 --- a/daemon/call.c +++ b/daemon/call.c @@ -616,17 +616,16 @@ static struct call_media *__get_media(struct call_monologue *ml, const struct st struct call_media *med; call_t *call; - // check for trickle ICE SDP fragment - if (flags->fragment && sp->media_id.len) { - // in this case, the media sections are out of order and the media ID - // string is used to determine which media section to operate on. this - // info must be present and valid. + if (sp->media_id.len) { + // in this case, the media sections can be out of order and the media ID + // string is used to determine which media section to operate on. med = g_hash_table_lookup(ml->media_ids, &sp->media_id); if (med) return med; - ilogs(ice, LOG_ERR, "Received trickle ICE SDP fragment with unknown media ID '" - STR_FORMAT "'", - STR_FMT(&sp->media_id)); + if (flags->trickle_ice) + ilogs(ice, LOG_ERR, "Received trickle ICE SDP fragment with unknown media ID '" + STR_FORMAT "'", + STR_FMT(&sp->media_id)); } unsigned int want_index = index;