Change the table used to hold the default timers to be global and const,

instead of allocating it on the stack each time the function is called.


git-svn-id: https://origsvn.digium.com/svn/libpri/trunk@494 2fbb986a-6c06-0410-b554-c9c1f0a7f128
This commit is contained in:
Russell Bryant
2007-12-06 03:44:59 +00:00
parent 79bb2373f9
commit 414fe8f956

2
pri.c
View File

@@ -81,7 +81,7 @@ char *pri_switch2str(int sw)
static void pri_default_timers(struct pri *pri, int switchtype)
{
int defaulttimers[20][PRI_MAX_TIMERS] = PRI_TIMERS_ALL;
static const int defaulttimers[20][PRI_MAX_TIMERS] = PRI_TIMERS_ALL;
int x;
for (x = 0; x<PRI_MAX_TIMERS; x++) {