From: Olle Johansson Date: Tue, 10 Oct 2006 19:23:36 +0000 (+0000) Subject: Do not set default/global values in the variable declaration, set it in reload_config() X-Git-Tag: 1.4.0-beta3~41 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=84a6a67b15aad82f3c6f4ca98f366203a26afc85;p=thirdparty%2Fasterisk.git Do not set default/global values in the variable declaration, set it in reload_config() git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/1.4@44830 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 812071b4a0..0cf3562a09 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -181,10 +181,10 @@ ASTERISK_FILE_VERSION(__FILE__, "$Revision$") below EXPIRY_GUARD_LIMIT */ #define DEFAULT_EXPIRY 900 /*!< Expire slowly */ -static int min_expiry = DEFAULT_MIN_EXPIRY; /*!< Minimum accepted registration time */ -static int max_expiry = DEFAULT_MAX_EXPIRY; /*!< Maximum accepted registration time */ -static int default_expiry = DEFAULT_DEFAULT_EXPIRY; -static int expiry = DEFAULT_EXPIRY; +static int min_expiry; /*!< Minimum accepted registration time */ +static int max_expiry; /*!< Maximum accepted registration time */ +static int default_expiry; +static int expiry; #ifndef MAX #define MAX(a,b) ((a) > (b) ? (a) : (b)) @@ -15679,6 +15679,10 @@ static int reload_config(enum channelreloadreason reason) allow_external_domains = DEFAULT_ALLOW_EXT_DOM; /* Allow external invites */ global_regcontext[0] = '\0'; expiry = DEFAULT_EXPIRY; + min_expiry = DEFAULT_MIN_EXPIRY; /*!< Minimum accepted registration time */ + max_expiry = DEFAULT_MAX_EXPIRY; /*!< Maximum accepted registration time */ + default_expiry = DEFAULT_DEFAULT_EXPIRY; + expiry = DEFAULT_EXPIRY; global_notifyringing = DEFAULT_NOTIFYRINGING; global_alwaysauthreject = 0; global_allowsubscribe = FALSE;