diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-05-22 16:05:18 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-05-22 16:05:18 +0000 |
commit | 2d9ba021dd38039616c82a4e317f652abe246ba3 (patch) | |
tree | e62b5224a8d99c2c625e0fb7c0f285514ec5f4f4 /apps/app_queue.c | |
parent | 890f6278bc082431b54b3ab3a6af0ce5abdfa539 (diff) |
Committing a fix pointed out by Atis Lezdins on the asterisk-dev list. Thanks!
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@117794 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'apps/app_queue.c')
-rw-r--r-- | apps/app_queue.c | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/apps/app_queue.c b/apps/app_queue.c index 4a4993215..904aebd6d 100644 --- a/apps/app_queue.c +++ b/apps/app_queue.c @@ -3943,12 +3943,15 @@ static int set_member_paused(const char *queuename, const char *interface, const ao2_ref(mem, -1); } } - ao2_unlock(q); - queue_unref(q); - if (!ast_strlen_zero(queuename) && found) { + if (!ast_strlen_zero(queuename) && !strcasecmp(queuename, q->name)) { + ao2_unlock(q); + queue_unref(q); break; } + + ao2_unlock(q); + queue_unref(q); } return found ? RESULT_SUCCESS : RESULT_FAILURE; |