[asterisk-commits] mmichelson: branch 1.6.1 r173695 - in /branches/1.6.1: ./ apps/app_queue.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Feb 5 14:35:43 CST 2009


Author: mmichelson
Date: Thu Feb  5 14:35:42 2009
New Revision: 173695

URL: http://svn.digium.com/svn-view/asterisk?view=rev&rev=173695
Log:
Merged revisions 173693 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/trunk

................
r173693 | mmichelson | 2009-02-05 14:30:45 -0600 (Thu, 05 Feb 2009) | 20 lines

Merged revisions 173692 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.4

........
r173692 | mmichelson | 2009-02-05 14:29:09 -0600 (Thu, 05 Feb 2009) | 12 lines

Fix situations where queue members could be autopaused unexpectedly

Specifically, this patch prevents us from autopausing members when
we receive a busy or congestion frame from them.

(closes issue #14376)
Reported by: fiddur
Patches:
      14376.patch uploaded by putnopvut (license 60)
Tested by: fiddur


........

................

Modified:
    branches/1.6.1/   (props changed)
    branches/1.6.1/apps/app_queue.c

Propchange: branches/1.6.1/
------------------------------------------------------------------------------
Binary property 'trunk-merged' - no diff available.

Modified: branches/1.6.1/apps/app_queue.c
URL: http://svn.digium.com/svn-view/asterisk/branches/1.6.1/apps/app_queue.c?view=diff&rev=173695&r1=173694&r2=173695
==============================================================================
--- branches/1.6.1/apps/app_queue.c (original)
+++ branches/1.6.1/apps/app_queue.c Thu Feb  5 14:35:42 2009
@@ -2481,7 +2481,7 @@
 }
 
 /*! \brief RNA == Ring No Answer. Common code that is executed when we try a queue member and they don't answer. */
-static void rna(int rnatime, struct queue_ent *qe, char *interface, char *membername)
+static void rna(int rnatime, struct queue_ent *qe, char *interface, char *membername, int pause)
 {
 	ast_verb(3, "Nobody picked up in %d ms\n", rnatime);
 	if (qe->parent->eventwhencalled)
@@ -2499,7 +2499,7 @@
 						membername,
 						rnatime);
 	ast_queue_log(qe->parent->name, qe->chan->uniqueid, membername, "RINGNOANSWER", "%d", rnatime);
-	if (qe->parent->autopause) {
+	if (qe->parent->autopause && pause) {
 		if (!set_member_paused(qe->parent->name, interface, "Auto-Pause", 1)) {
 			ast_verb(3, "Auto-Pausing Queue Member %s in queue %s since they failed to answer.\n", interface, qe->parent->name);
 		} else {
@@ -2678,7 +2678,7 @@
 							do_hang(o);
 							endtime = (long) time(NULL);
 							endtime -= starttime;
-							rna(endtime*1000, qe, on, membername);
+							rna(endtime * 1000, qe, on, membername, 0);
 							if (qe->parent->strategy != QUEUE_STRATEGY_RINGALL) {
 								if (qe->parent->timeoutrestart)
 									*to = orig;
@@ -2692,7 +2692,7 @@
 								ast_cdr_busy(in->cdr);
 							endtime = (long) time(NULL);
 							endtime -= starttime;
-							rna(endtime*1000, qe, on, membername);
+							rna(endtime * 1000, qe, on, membername, 0);
 							do_hang(o);
 							if (qe->parent->strategy != QUEUE_STRATEGY_RINGALL) {
 								if (qe->parent->timeoutrestart)
@@ -2714,7 +2714,7 @@
 					ast_frfree(f);
 				} else {
 					endtime = (long) time(NULL) - starttime;
-					rna(endtime * 1000, qe, on, membername);
+					rna(endtime * 1000, qe, on, membername, 1);
 					do_hang(o);
 					if (qe->parent->strategy != QUEUE_STRATEGY_RINGALL) {
 						if (qe->parent->timeoutrestart)
@@ -2754,7 +2754,7 @@
 		}
 		if (!*to) {
 			for (o = start; o; o = o->call_next)
-				rna(orig, qe, o->interface, o->member->membername);
+				rna(orig, qe, o->interface, o->member->membername, 1);
 		}
 	}
 




More information about the asterisk-commits mailing list