From: James Golovich Date: Thu, 1 Jul 2004 04:04:30 +0000 (+0000) Subject: Fix IAX2 registration time. We want to set reg->refresh to the new value only if... X-Git-Tag: 1.0.0-rc1~90 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=201849fb42757e61e9e0b463af8f11f5783faf03;p=thirdparty%2Fasterisk.git Fix IAX2 registration time. We want to set reg->refresh to the new value only if its lower not if its higher. (bug 1955) git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@3369 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_iax2.c b/channels/chan_iax2.c index 1196949cb7..188afff65f 100755 --- a/channels/chan_iax2.c +++ b/channels/chan_iax2.c @@ -4035,7 +4035,7 @@ static int iax2_ack_registry(struct iax_ies *ies, struct sockaddr_in *sin, int c } memcpy(®->us, &us, sizeof(reg->us)); reg->messages = ies->msgcount; - if (refresh && (reg->refresh < refresh)) { + if (refresh && (reg->refresh > refresh)) { /* Refresh faster if necessary */ reg->refresh = refresh; if (reg->expire > -1)