From 446f14f0dccc3958f8b03ef848662da66fcfcc04 Mon Sep 17 00:00:00 2001 From: Joshua Colp Date: Tue, 10 Jul 2007 14:07:13 +0000 Subject: [PATCH] Only spit out an inringing warning message when it is applicable. Since call limits are already toast in realtime let's not scare the user if they are using it. (issue #10166 reported by bcnit) git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@74262 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- channels/chan_sip.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/channels/chan_sip.c b/channels/chan_sip.c index ccc77314e4..f0a0c047c3 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -3095,7 +3095,7 @@ static int update_call_counter(struct sip_pvt *fup, int event) if (ast_test_flag(&fup->flags[1], SIP_PAGE2_INC_RINGING)) { if (*inringing > 0) (*inringing)--; - else + else if (!ast_test_flag(&fup->flags[0], SIP_REALTIME) || ast_test_flag(&fup->flags[1], SIP_PAGE2_RTCACHEFRIENDS)) ast_log(LOG_WARNING, "Inringing for peer '%s' < 0?\n", fup->peername); ast_clear_flag(&fup->flags[1], SIP_PAGE2_INC_RINGING); } @@ -3138,7 +3138,7 @@ static int update_call_counter(struct sip_pvt *fup, int event) if (ast_test_flag(&fup->flags[1], SIP_PAGE2_INC_RINGING)) { if (*inringing > 0) (*inringing)--; - else + else if (!ast_test_flag(&fup->flags[0], SIP_REALTIME) || ast_test_flag(&fup->flags[1], SIP_PAGE2_RTCACHEFRIENDS)) ast_log(LOG_WARNING, "Inringing for peer '%s' < 0?\n", p->name); ast_clear_flag(&fup->flags[1], SIP_PAGE2_INC_RINGING); }