[Asterisk-code-review] app_queue: Member lastpause time reseting (asterisk[18])

Friendly Automation asteriskteam at digium.com
Tue Aug 25 17:29:08 CDT 2020


Friendly Automation has submitted this change. ( https://gerrit.asterisk.org/c/asterisk/+/14805 )

Change subject: app_queue: Member lastpause time reseting
......................................................................

app_queue: Member lastpause time reseting

This fixes the reseting members lastpause problem when realtime members is being used,
the function rt_handle_member_record was forcing the reset members lastpause because it
does not exist in realtime

ASTERISK-29034 #close

Change-Id: Ic9107e4456732a1f78412a32adb2ef87f5da40b5
---
M apps/app_queue.c
1 file changed, 1 insertion(+), 1 deletion(-)

Approvals:
  Joshua Colp: Looks good to me, but someone else must approve
  Kevin Harwell: Looks good to me, approved
  Sean Bright: Looks good to me, but someone else must approve
  Friendly Automation: Approved for Submit



diff --git a/apps/app_queue.c b/apps/app_queue.c
index 19622fd..ba206eb 100644
--- a/apps/app_queue.c
+++ b/apps/app_queue.c
@@ -3458,7 +3458,7 @@
 			ast_copy_string(m->rt_uniqueid, rt_uniqueid, sizeof(m->rt_uniqueid));
 			if (paused_str) {
 				m->paused = paused;
-				if (paused) {
+				if (paused && m->lastpause == 0) {
 					time(&m->lastpause); /* XXX: Should this come from realtime? */
 				}
 				ast_devstate_changed(m->paused ? QUEUE_PAUSED_DEVSTATE : QUEUE_UNPAUSED_DEVSTATE,

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

Gerrit-Project: asterisk
Gerrit-Branch: 18
Gerrit-Change-Id: Ic9107e4456732a1f78412a32adb2ef87f5da40b5
Gerrit-Change-Number: 14805
Gerrit-PatchSet: 2
Gerrit-Owner: Evandro César Arruda <ecarruda at gmail.com>
Gerrit-Reviewer: Friendly Automation
Gerrit-Reviewer: Joshua Colp <jcolp at sangoma.com>
Gerrit-Reviewer: Kevin Harwell <kharwell at digium.com>
Gerrit-Reviewer: Sean Bright <sean.bright at gmail.com>
Gerrit-MessageType: merged
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.digium.com/pipermail/asterisk-code-review/attachments/20200825/d0323df7/attachment.html>


More information about the asterisk-code-review mailing list