diff options
author | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-05-29 16:29:04 +0000 |
---|---|---|
committer | russell <russell@f38db490-d61c-443f-a65b-d21fe96a405b> | 2009-05-29 16:29:04 +0000 |
commit | 90fd88258e4f9f56140cb6bbdaba27eea19eb918 (patch) | |
tree | 33cbda680cda0646536bf27f3d8b5521fce6ff30 | |
parent | cea900cdc44f463a82e8175356ff68c8d01944d4 (diff) |
Merged revisions 197960 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
........
r197960 | russell | 2009-05-29 11:15:30 -0500 (Fri, 29 May 2009) | 2 lines
Trim trailing whitespace so that I can work on this bug without it bothering me. :-)
........
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.2@197994 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r-- | res/res_timing_pthread.c | 22 |
1 files changed, 11 insertions, 11 deletions
diff --git a/res/res_timing_pthread.c b/res/res_timing_pthread.c index a45287588..8eea1a0f9 100644 --- a/res/res_timing_pthread.c +++ b/res/res_timing_pthread.c @@ -16,11 +16,11 @@ * at the top of the source tree. */ -/*! +/*! * \file * \author Russell Bryant <russell@digium.com> * - * \brief pthread timing interface + * \brief pthread timing interface */ #include "asterisk.h" @@ -186,7 +186,7 @@ static int pthread_timer_set_rate(int handle, unsigned int rate) if (timer->state != TIMER_STATE_CONTINUOUS) { set_state(timer); } - + ao2_unlock(timer); ao2_ref(timer, -1); @@ -311,7 +311,7 @@ static void pthread_timer_destructor(void *obj) } /*! - * \note only PIPE_READ is guaranteed valid + * \note only PIPE_READ is guaranteed valid */ static int pthread_timer_hash(const void *obj, const int flags) { @@ -321,7 +321,7 @@ static int pthread_timer_hash(const void *obj, const int flags) } /*! - * \note only PIPE_READ is guaranteed valid + * \note only PIPE_READ is guaranteed valid */ static int pthread_timer_cmp(void *obj, void *arg, int flags) { @@ -339,9 +339,9 @@ static int check_timer(struct pthread_timer *timer) struct timeval now; if (timer->state == TIMER_STATE_IDLE || timer->state == TIMER_STATE_CONTINUOUS) { - return 0; + return 0; } - + now = ast_tvnow(); if (timer->tick_count < (ast_tvdiff_ms(now, timer->start) / timer->interval)) { @@ -379,7 +379,7 @@ static void read_pipe(int rd_fd, unsigned int quantity, int clear) break; } - res = read(rd_fd, buf, + res = read(rd_fd, buf, (quantity < sizeof(buf)) ? quantity : sizeof(buf)); if (res == -1) { @@ -404,7 +404,7 @@ static void write_byte(int wr_fd) ssize_t res; unsigned char x = 42; - res = write(wr_fd, &x, 1); + res = write(wr_fd, &x, 1); if (res == -1) { if (errno == EAGAIN) { @@ -428,7 +428,7 @@ static int run_timer(void *obj, void *arg, int flags) if (check_timer(timer)) { write_byte(timer->pipe[PIPE_WRITE]); } - + ao2_unlock(timer); return 0; @@ -477,7 +477,7 @@ static int init_timing_thread(void) static int load_module(void) { - if (!(pthread_timers = ao2_container_alloc(PTHREAD_TIMER_BUCKETS, + if (!(pthread_timers = ao2_container_alloc(PTHREAD_TIMER_BUCKETS, pthread_timer_hash, pthread_timer_cmp))) { return AST_MODULE_LOAD_DECLINE; } |