fix monitor thread. Bug #726

git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@1976 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
Jeremy McNamara 2004-01-12 06:10:54 +00:00
parent 92f261cf3b
commit e08cce6b6b
1 changed files with 1 additions and 1 deletions

View File

@ -7048,7 +7048,7 @@ static int __unload_module(void)
return -1;
}
if (!ast_mutex_lock(&monlock)) {
if (monitor_thread) {
if (monitor_thread && (monitor_thread != -2)) {
pthread_cancel(monitor_thread);
pthread_kill(monitor_thread, SIGURG);
pthread_join(monitor_thread, NULL);