[Asterisk-cvs] asterisk/apps app_queue.c,1.83,1.84

markster at lists.digium.com markster at lists.digium.com
Fri Sep 10 11:09:37 CDT 2004


Update of /usr/cvsroot/asterisk/apps
In directory mongoose.digium.com:/tmp/cvs-serv14272/apps

Modified Files:
	app_queue.c 
Log Message:
Properly lock management stuff (bug #2406)


Index: app_queue.c
===================================================================
RCS file: /usr/cvsroot/asterisk/apps/app_queue.c,v
retrieving revision 1.83
retrieving revision 1.84
diff -u -d -r1.83 -r1.84
--- app_queue.c	2 Sep 2004 04:07:28 -0000	1.83
+++ app_queue.c	10 Sep 2004 15:11:37 -0000	1.84
@@ -2047,6 +2047,7 @@
 		/* List queue properties */
 		if(q->callscompleted > 0)
 			sl = 100*((float)q->callscompletedinsl/(float)q->callscompleted);
+		ast_mutex_lock(&s->lock);
 		ast_cli(s->fd, "Event: QueueParams\r\n"
 					"Queue: %s\r\n"
 					"Max: %d\r\n"
@@ -2088,6 +2089,7 @@
 				"%s"
 				"\r\n", 
 					q->name, pos++, qe->chan->name, (qe->chan->callerid ? qe->chan->callerid : ""), (long)(now - qe->start), idText);
+		ast_mutex_unlock(&s->lock);
 		ast_mutex_unlock(&q->lock);
 	}
 	ast_mutex_unlock(&qlock);




More information about the svn-commits mailing list