From: Mark Spencer Date: Thu, 9 Sep 2004 01:33:17 +0000 (+0000) Subject: Don't consider RTP timeout if the channel isn't up X-Git-Tag: 1.0.0~79 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=cb896da99810029f8a3e639007e9062c1f2b1000;p=thirdparty%2Fasterisk.git Don't consider RTP timeout if the channel isn't up git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3747 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index c14fd44d04..502ca60da8 100755 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -7650,7 +7650,7 @@ restartsearch: sip = iflist; while(sip) { ast_mutex_lock(&sip->lock); - if (sip->rtp && sip->lastrtprx && (sip->rtptimeout || sip->rtpholdtimeout) && !sip->redirip.sin_addr.s_addr) { + if (sip->rtp && sip->owner && (sip->owner->_state == AST_STATE_UP) && sip->lastrtprx && (sip->rtptimeout || sip->rtpholdtimeout) && !sip->redirip.sin_addr.s_addr) { if (t > sip->lastrtprx + sip->rtptimeout) { /* Might be a timeout now -- see if we're on hold */ struct sockaddr_in sin;