[asterisk-commits] nadi: branch 1.4 r44921 - /branches/1.4/main/manager.c

asterisk-commits at lists.digium.com asterisk-commits at lists.digium.com
Thu Oct 12 05:55:26 MST 2006


Author: nadi
Date: Thu Oct 12 07:55:25 2006
New Revision: 44921

URL: http://svn.digium.com/view/asterisk?rev=44921&view=rev
Log:
append_event must be called while holding the session lock

Modified:
    branches/1.4/main/manager.c

Modified: branches/1.4/main/manager.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/main/manager.c?rev=44921&r1=44920&r2=44921&view=diff
==============================================================================
--- branches/1.4/main/manager.c (original)
+++ branches/1.4/main/manager.c Thu Oct 12 07:55:25 2006
@@ -2263,10 +2263,9 @@
 	
 	ast_dynamic_str_thread_append(&buf, 0, &manager_event_buf, "\r\n");	
 	
-	append_event(buf->str, category);
-	
 	/* Append even to master list and wake up any sleeping sessions */
 	AST_LIST_LOCK(&sessions);
+	append_event(buf->str, category);
 	AST_LIST_TRAVERSE(&sessions, s, list) {
 		ast_mutex_lock(&s->__lock);
 		if (s->waiting_thread != AST_PTHREADT_NULL)



More information about the asterisk-commits mailing list