diff options
author | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2004-03-20 05:19:45 +0000 |
---|---|---|
committer | markster <markster@f38db490-d61c-443f-a65b-d21fe96a405b> | 2004-03-20 05:19:45 +0000 |
commit | 6af94b4263f18e260011f007e0ba21ac14347244 (patch) | |
tree | eec323806c1dce7ed848b01d22a8fbf26486fefc /rtp.c | |
parent | 7eeda1510b01615d5a22a21094eaf52eba7a4626 (diff) |
Round offset timestamps to nearest 20ms to clean up numbers.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@2486 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'rtp.c')
-rwxr-xr-x | rtp.c | 1 |
1 files changed, 1 insertions, 0 deletions
@@ -366,6 +366,7 @@ static void calc_rxstamp(struct timeval *tv, struct ast_rtp *rtp, unsigned int t gettimeofday(&rtp->rxcore, NULL); rtp->rxcore.tv_sec -= timestamp / 8000; rtp->rxcore.tv_usec -= (timestamp % 8000) * 125; + rtp->rxcore.tv_usec -= rtp->rxcore.tv_usec % 20000; if (rtp->rxcore.tv_usec < 0) { /* Adjust appropriately if necessary */ rtp->rxcore.tv_usec += 1000000; |