[asterisk-commits] russell: branch 1.4 r73598 - /branches/1.4/channels/chan_sip.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Thu Jul 5 18:59:22 CDT 2007


Author: russell
Date: Thu Jul  5 18:59:22 2007
New Revision: 73598

URL: http://svn.digium.com/view/asterisk?view=rev&rev=73598
Log:
Fix a crash in chan_sip.  Don't try to stop the monitor thread if it was never
started.  (closes issue #10124, reported by gzero, fixed by me)

Modified:
    branches/1.4/channels/chan_sip.c

Modified: branches/1.4/channels/chan_sip.c
URL: http://svn.digium.com/view/asterisk/branches/1.4/channels/chan_sip.c?view=diff&rev=73598&r1=73597&r2=73598
==============================================================================
--- branches/1.4/channels/chan_sip.c (original)
+++ branches/1.4/channels/chan_sip.c Thu Jul  5 18:59:22 2007
@@ -17642,7 +17642,7 @@
 	ast_mutex_unlock(&iflock);
 
 	ast_mutex_lock(&monlock);
-	if (monitor_thread && (monitor_thread != AST_PTHREADT_STOP)) {
+	if (monitor_thread && (monitor_thread != AST_PTHREADT_STOP) && (monitor_thread != AST_PTHREADT_NULL)) {
 		pthread_cancel(monitor_thread);
 		pthread_kill(monitor_thread, SIGURG);
 		pthread_join(monitor_thread, NULL);




More information about the asterisk-commits mailing list