]> git.ipfire.org Git - thirdparty/asterisk.git/commit
app_queue: AgentComplete event has wrong reason 80/1280/1
authorKevin Harwell <kharwell@digium.com>
Thu, 17 Sep 2015 21:47:33 +0000 (16:47 -0500)
committerKevin Harwell <kharwell@digium.com>
Thu, 17 Sep 2015 21:47:33 +0000 (16:47 -0500)
commit4fb95bbc4e4928dd3403a20d401c285a568f0d09
treeed4cc924d95336519fc373dab092bb94dab67650
parenta665b3128177fc87036d7eb8b3174ac85e791d22
app_queue: AgentComplete event has wrong reason

When a queued caller transfers an agent to another extension sometimes the
raised AgentComplete event has a reason of "caller" and sometimes "transfer".
Since a transfer has taken place this should always be transfer. This occurs
because sometimes the stasis hangup event arrives before the transfer event
thus writing a different reason out.

With this patch, when a hangup event is received during a transfer it will
check to see if the channel that is hanging up is part of a transfer. If so
it will return and let the subsequently received transfer event handler take
care of the cleanup.

ASTERISK-25399 #close

Change-Id: Ic63c49bd9a5ed463ea7a032fd2ea3d63bc81a50d
apps/app_queue.c