]> git.ipfire.org Git - thirdparty/asterisk.git/commit
app_queue: Only remove queue member from pending when state changes. 14/4814/2
authorJoshua Colp <jcolp@digium.com>
Thu, 14 Jul 2016 12:45:10 +0000 (09:45 -0300)
committerGeorge Joseph <gjoseph@digium.com>
Sun, 29 Jan 2017 17:53:24 +0000 (11:53 -0600)
commitbbb041a1cfabc62dffd360481d3a1365111c1519
tree54e14420dda8f46a45077226fad6daa031397260
parent4574a24429cf94b8e2a07baa59033d173b302e3b
app_queue: Only remove queue member from pending when state changes.

It is possible for a not in use state change to occur multiple
times causing a queue member to be removed from the pending call
container prematurely.

The first not in use state change will remove the queue member
from the container. At this moment the member may be called and
placed in the pending container. After this another not in use
state change can be received which will remove it from the
container. Despite being called at this point the code will
incorrectly see that there are no pending calls to it.

This change only removes it from the pending container if the
state has actually changed.

ASTERISK-26133 #close
patches:
  app_queue.diff submitted by Richard Miller (license 5685)

Change-Id: Ie5a7f17a44f98e9159e9b85009ce3f8393aa78c0
(cherry picked from commit 8a4546146542e867e085d201e5cf164e9d6532a4)
apps/app_queue.c