timer mojo (cont)

git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@4150 d0543943-73ff-0310-b7d9-9358b9ac24b2
This commit is contained in:
Anthony Minessale committed 2007-02-07 19:01:07 +00:00
1 parent 66feec2da5
commit e216bbe095
3 files changed
+16 -12

No files matched your search

+7 -1
View File
@@ -95,7 +95,13 @@ static inline switch_status_t timer_next(switch_timer_t *timer)
uint64_t diff;
if ((diff = (private_info->reference - TIMER_MATRIX[timer->interval].tick))) {
switch_yield(diff * 1000);
if (diff == timer->interval) {
switch_yield(diff * 500);
} else {
switch_yield(1000);
}
} else {
break;
}
}
timer->samplecount += timer->samples;