]> git.ipfire.org Git - thirdparty/freeswitch.git/commitdiff
MODAPP-211
authorAnthony Minessale <anthony.minessale@gmail.com>
Wed, 11 Feb 2009 00:31:58 +0000 (00:31 +0000)
committerAnthony Minessale <anthony.minessale@gmail.com>
Wed, 11 Feb 2009 00:31:58 +0000 (00:31 +0000)
git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@11741 d0543943-73ff-0310-b7d9-9358b9ac24b2

src/mod/applications/mod_enum/mod_enum.c
src/switch_time.c

index 319570d1ee78dbfe03aed5bef517c3273616a529..20d6e919c555a6ba264f918dbd7d662f90773c4d 100644 (file)
@@ -802,7 +802,9 @@ SWITCH_STANDARD_API(enum_function)
 static void event_handler(switch_event_t *event)
 {
        if (globals.auto_reload) {
+               switch_mutex_lock(MUTEX);
                do_load();
+               switch_mutex_unlock(MUTEX);
                switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_INFO, "ENUM Reloaded\n");
        }
 }
index 7a402f0ba3553ac473fe1b3aa405f4ec41f080a2..2e65628c1501a54231c29dbaeb6eb7dac5985985 100644 (file)
@@ -658,7 +658,9 @@ void switch_load_timezones(switch_bool_t reload)
 
 static void event_handler(switch_event_t *event)
 {
+       switch_mutex_lock(globals.mutex);
        switch_load_timezones(1);
+       switch_mutex_unlock(globals.mutex);
 }
 
 static void tztime(const time_t * const timep, const char *tzstring, struct tm * const tmp );