Merged revisions 63830 via svnmerge from
[asterisk/asterisk.git] / channels / chan_iax2.c
index a92e59c..8f6b373 100644 (file)
@@ -2506,7 +2506,8 @@ static int iax2_transmit(struct iax_frame *fr)
        AST_LIST_INSERT_TAIL(&queue, fr, list);
        AST_LIST_UNLOCK(&queue);
        /* Wake up the network and scheduler thread */
-       pthread_kill(netthreadid, SIGURG);
+       if (netthreadid != AST_PTHREADT_NULL)
+               pthread_kill(netthreadid, SIGURG);
        signal_condition(&sched_lock, &sched_cond);
        return 0;
 }