aboutsummaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorbweschke <bweschke@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-23 11:30:17 +0000
committerbweschke <bweschke@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-23 11:30:17 +0000
commit0448dd3ce810aeac0abb36180e530b34d16be105 (patch)
treeba89fc5110e6bc9e043f47ef33100af0ac899eba /apps
parent0bb1814675153a8a80da1f9a03c5ee142a65a929 (diff)
We should lock the queue before we go making changes to member interface statuses.
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.2@35669 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps')
-rw-r--r--apps/app_queue.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/apps/app_queue.c b/apps/app_queue.c
index 1bb0420e3..e336fa231 100644
--- a/apps/app_queue.c
+++ b/apps/app_queue.c
@@ -3425,9 +3425,11 @@ static void reload_queues(void)
} else
ast_log(LOG_WARNING, "XXX Leaking a little memory :( XXX\n");
} else {
+ ast_mutex_lock(&q->lock);
for (cur = q->members; cur; cur = cur->next)
cur->status = ast_device_state(cur->interface);
ql = q;
+ ast_mutex_unlock(&q->lock);
}
q = qn;
}