From 24ae7007b6cfe06c0dd86d0d7b83b1fbbadddaaa Mon Sep 17 00:00:00 2001 From: Richard Fuchs Date: Wed, 7 Dec 2022 09:05:22 -0500 Subject: [PATCH] MT#55984 cancel scheduled deletion during offer/answer Unmark a monologue that has been scheduled for deletion when it's associated with another one, which happens during offer/answer. Fixes a regression from 53dbef7e1 which removed this logic from __monologue_unkernelize with re-adding it elsewhere. Change-Id: I037162e91fec42631680f7767f58b172fd6e04db (cherry picked from commit afb42551c43564a0d80ab0609a0ac73d29e6a507) --- daemon/call.c | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) diff --git a/daemon/call.c b/daemon/call.c index 4fb16d0a4..a85d77b12 100644 --- a/daemon/call.c +++ b/daemon/call.c @@ -4108,8 +4108,17 @@ struct call_monologue *call_get_or_create_monologue(struct call *call, const str return ret; } -/* must be called with call->master_lock held in W */ +/** + * Must be called with call->master_lock held in W. + * + * Also cancel scheduled deletion during offer/answer: + * + * Unmark a monologue that has been scheduled for deletion when it's + * associated with another one, which happens during offer/answer. + */ static void __tags_associate(struct call_monologue *a, struct call_monologue *b) { + a->deleted = 0; + b->deleted = 0; g_hash_table_insert(a->associated_tags, b, b); g_hash_table_insert(b->associated_tags, a, a); }