From c985853cbffc641d790c9e2ed7b0c2876e852f5a Mon Sep 17 00:00:00 2001 From: Travis Cross Date: Tue, 8 May 2012 20:45:05 +0000 Subject: [PATCH] mod_posix_timer: we'll find a better way to comply with gcc -pedantic on lucid We shouldn't be logging in a signal handler. This reverts commit c728efdbb987834f8d76dac51132d0a724380902. --- src/mod/timers/mod_posix_timer/mod_posix_timer.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/mod/timers/mod_posix_timer/mod_posix_timer.c b/src/mod/timers/mod_posix_timer/mod_posix_timer.c index c170d8fa20..04d694b5f7 100644 --- a/src/mod/timers/mod_posix_timer/mod_posix_timer.c +++ b/src/mod/timers/mod_posix_timer/mod_posix_timer.c @@ -111,9 +111,7 @@ static void timer_signal_handler(int sig, siginfo_t *si, void *cu) if (val >= 0 && val <= MAX_ACTIVE_TIMERS) { uint8_t active_id = (uint8_t)val; /* notify runtime thread that timer identified by active_id has ticked */ - if (write(globals.timer_tick_pipe[1], &active_id, 1) == -1) { - switch_log_printf(SWITCH_CHANNEL_LOG, SWITCH_LOG_ERROR, "Error writing to pipe: %s\n", strerror(errno)); - } + write(globals.timer_tick_pipe[1], &active_id, 1); } } }