aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--apps/app_queue.c4
1 files changed, 4 insertions, 0 deletions
diff --git a/apps/app_queue.c b/apps/app_queue.c
index ced7933f9..a93147cac 100644
--- a/apps/app_queue.c
+++ b/apps/app_queue.c
@@ -1198,7 +1198,9 @@ static struct call_queue *find_queue_by_name_rt(const char *queuename, struct as
} else {
q->members = next_m;
}
+ ast_mutex_unlock(&q->lock);
remove_from_interfaces(m->interface);
+ ast_mutex_lock(&q->lock);
q->membercount--;
ast_free(m);
} else {
@@ -1300,7 +1302,9 @@ static void update_realtime_members(struct call_queue *q)
} else {
q->members = next_m;
}
+ ast_mutex_unlock(&q->lock);
remove_from_interfaces(m->interface);
+ ast_mutex_lock(&q->lock);
q->membercount--;
free(m);
} else {