diff options
author | tilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-10-31 16:30:32 +0000 |
---|---|---|
committer | tilghman <tilghman@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-10-31 16:30:32 +0000 |
commit | 8a84d91c4b7fae45cbcbbada6fdb5adc9f5ea3a7 (patch) | |
tree | 858e029706c1806fb6f9b76327c07bf05d022447 /channels | |
parent | 9192321f1e2aaa11979415d54eac9d38ba8ee0cd (diff) |
Turn off qualify on uncached realtime peers.
(Closes issue #13383)
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.4@153114 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r-- | channels/chan_sip.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 979b5de50..b040238c2 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -17326,6 +17326,14 @@ static struct sip_peer *build_peer(const char *name, struct ast_variable *v, str ast_log(LOG_WARNING, "Qualification of peer '%s' should be 'yes', 'no', or a number of milliseconds at line %d of sip.conf\n", peer->name, v->lineno); peer->maxms = 0; } + if (realtime && !ast_test_flag(&global_flags[1], SIP_PAGE2_RTCACHEFRIENDS) && peer->maxms > 0) { + /* This would otherwise cause a network storm, where the + * qualify response refreshes the peer from the database, + * which in turn causes another qualify to be sent, ad + * infinitum. */ + ast_log(LOG_WARNING, "Qualify is incompatible with dynamic uncached realtime. Please either turn rtcachefriends on or turn qualify off on peer '%s'\n", peer->name); + peer->maxms = 0; + } } else if (!strcasecmp(v->name, "maxcallbitrate")) { peer->maxcallbitrate = atoi(v->value); if (peer->maxcallbitrate < 0) |