[svn-commits] trunk r34194 - /trunk/apps/app_queue.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Wed Jun 14 16:24:27 MST 2006


Author: kpfleming
Date: Wed Jun 14 18:24:26 2006
New Revision: 34194

URL: http://svn.digium.com/view/asterisk?rev=34194&view=rev
Log:
use the proper named constants for checking device state, and don't treat UNKNOWN as not available in autofill mode

Modified:
    trunk/apps/app_queue.c

Modified: trunk/apps/app_queue.c
URL: http://svn.digium.com/view/asterisk/trunk/apps/app_queue.c?rev=34194&r1=34193&r2=34194&view=diff
==============================================================================
--- trunk/apps/app_queue.c (original)
+++ trunk/apps/app_queue.c Wed Jun 14 18:24:26 2006
@@ -2037,11 +2037,13 @@
 				ast_log(LOG_DEBUG, "Even though there are %d available members, the strategy is ringall so only the head call is allowed in\n", avl);
 			avl = 1;
 		} else {
-			cur = qe->parent->members;
-			while (cur) {
-				if (cur->status == 1) 
+			for (cur = qe->parent->members; cur; cur = cur->next) {
+				switch (cur->status) {
+				case AST_DEVICE_NOT_INUSE:
+				case AST_DEVICE_UNKNOWN:
 					avl++;
-				cur = cur->next;
+					break;
+				}
 			}
 		}
 



More information about the svn-commits mailing list