From 15a71f4070ffd4b75e518a2503f6d34a5c42a730 Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Sun, 21 Sep 2025 13:05:02 -0400 Subject: [PATCH] MT#63317 fix off by one Change-Id: I4fa5b6819e55e6cc42a6fbe9f0db8ffa2e7b384d Warned-by: Coverity --- daemon/call.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/daemon/call.c b/daemon/call.c index 1dd854f50..4c7610529 100644 --- a/daemon/call.c +++ b/daemon/call.c @@ -3593,8 +3593,8 @@ static void monologue_bundle_mid(struct call_monologue *ml) { "%u/'" STR_FORMAT "'), removing it in favour of MID", ext->id, ext_exist->id, STR_FMT(&ext_exist->name)); t_hash_table_remove(media->extmap_ht, GUINT_TO_POINTER(ext_exist->id)); - if (ext_exist->id <= 14) - media->extmap_a[ext_exist->id] = NULL; + if (ext_exist->id > 0 && ext_exist->id <= 14) + media->extmap_a[ext_exist->id - 1] = NULL; t_queue_remove(&media->extmap, ext_exist); // XXX also not ideal rtp_extension_free(ext_exist); }