diff options
-rwxr-xr-x | channels/chan_sip.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c index c14fd44d0..502ca60da 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; |