[svn-commits] trunk r30034 - in /trunk: ./ logger.c

svn-commits at lists.digium.com svn-commits at lists.digium.com
Wed May 24 12:16:08 MST 2006


Author: file
Date: Wed May 24 14:16:07 2006
New Revision: 30034

URL: http://svn.digium.com/view/asterisk?rev=30034&view=rev
Log:
Merged revisions 30033 via svnmerge from 
https://origsvn.digium.com/svn/asterisk/branches/1.2

........
r30033 | file | 2006-05-24 16:14:01 -0300 (Wed, 24 May 2006) | 2 lines

Fix deadlock caused by a race condition in the logger when reloading (issue #7195 reported and fixed by softins)

........

Modified:
    trunk/   (props changed)
    trunk/logger.c

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.2-merged' - no diff available.

Modified: trunk/logger.c
URL: http://svn.digium.com/view/asterisk/trunk/logger.c?rev=30034&r1=30033&r2=30034&view=diff
==============================================================================
--- trunk/logger.c (original)
+++ trunk/logger.c Wed May 24 14:16:07 2006
@@ -385,6 +385,7 @@
 	FILE *myf;
 	int x, res = 0;
 
+	ast_mutex_lock(&msglist_lock);	/* to avoid deadlock */
 	ast_mutex_lock(&loglock);
 	if (eventlog) 
 		fclose(eventlog);
@@ -491,6 +492,7 @@
 		}
 	}
 	ast_mutex_unlock(&loglock);
+	ast_mutex_unlock(&msglist_lock);
 
 	return res;
 }



More information about the svn-commits mailing list