If we set a value for qualify, we should actually pay attention to it, instead of overriding the value

git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@89246 65c4cc65-6c06-0410-ace0-fbb531ad65f3
1.4
Tilghman Lesher 19 years ago
parent dc6e3e9d5d
commit 4332b72082

@ -15596,7 +15596,7 @@ static int sip_poke_peer(struct sip_peer *peer)
else {
if (peer->pokeexpire > -1)
ast_sched_del(sched, peer->pokeexpire);
peer->pokeexpire = ast_sched_add(sched, DEFAULT_MAXMS * 2, sip_poke_noanswer, peer);
peer->pokeexpire = ast_sched_add(sched, peer->maxms * 2, sip_poke_noanswer, peer);
}
return 0;
@ -16502,7 +16502,7 @@ static struct sip_peer *build_peer(const char *name, struct ast_variable *v, str
if (!strcasecmp(v->value, "no")) {
peer->maxms = 0;
} else if (!strcasecmp(v->value, "yes")) {
peer->maxms = DEFAULT_MAXMS;
peer->maxms = default_qualify ? default_qualify : DEFAULT_MAXMS;
} else if (sscanf(v->value, "%d", &peer->maxms) != 1) {
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;

Loading…
Cancel
Save