[Asterisk-code-review] app_queue: Fix leave-empty sometimes not recording a call as abandoned (asterisk[16])

Kfir Itzhak asteriskteam at digium.com
Wed Aug 26 04:58:24 CDT 2020


Kfir Itzhak has uploaded this change for review. ( https://gerrit.asterisk.org/c/asterisk/+/14811 )


Change subject: app_queue: Fix leave-empty sometimes not recording a call as abandoned
......................................................................

app_queue: Fix leave-empty sometimes not recording a call as abandoned

This fixes a bug introduced mistakenly in ASTERISK-25665:
If leave-empty is enabled, a call may sometimes be removed from a queue without recording it as abandoned.
This causes Asterisk to not generate an abandon event for that call, and for the queue abandoned counter to be incorrect.

ASTERISK-29043 #close

Change-Id: I1a71b81df78adff59af587f1d8483cf57df430c7
---
M apps/app_queue.c
1 file changed, 1 insertion(+), 0 deletions(-)



  git pull ssh://gerrit.asterisk.org:29418/asterisk refs/changes/11/14811/1

diff --git a/apps/app_queue.c b/apps/app_queue.c
index b13dc78..076b651 100644
--- a/apps/app_queue.c
+++ b/apps/app_queue.c
@@ -5644,6 +5644,7 @@
 			int status = 0;
 
 			if ((status = get_member_status(qe->parent, qe->max_penalty, qe->min_penalty, qe->raise_penalty, qe->parent->leavewhenempty, 0))) {
+				record_abandoned(qe);
 				*reason = QUEUE_LEAVEEMPTY;
 				ast_queue_log(qe->parent->name, ast_channel_uniqueid(qe->chan), "NONE", "EXITEMPTY", "%d|%d|%ld", qe->pos, qe->opos, (long) (time(NULL) - qe->start));
 				res = -1;

-- 
To view, visit https://gerrit.asterisk.org/c/asterisk/+/14811
To unsubscribe, or for help writing mail filters, visit https://gerrit.asterisk.org/settings

Gerrit-Project: asterisk
Gerrit-Branch: 16
Gerrit-Change-Id: I1a71b81df78adff59af587f1d8483cf57df430c7
Gerrit-Change-Number: 14811
Gerrit-PatchSet: 1
Gerrit-Owner: Kfir Itzhak <mastertheknife at gmail.com>
Gerrit-MessageType: newchange
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200826/4c07d1c9/attachment-0001.html>


More information about the asterisk-code-review mailing list