mirror of
https://github.com/asterisk/asterisk.git
synced 2025-11-05 03:40:18 +00:00
use existing sample size in frame instead of recalculating it (issue #5390)
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@6781 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
2
rtp.c
2
rtp.c
@@ -1231,7 +1231,7 @@ static int ast_rtp_raw_write(struct ast_rtp *rtp, struct ast_frame *f, int codec
|
|||||||
ms = calc_txstamp(rtp, &f->delivery);
|
ms = calc_txstamp(rtp, &f->delivery);
|
||||||
/* Default prediction */
|
/* Default prediction */
|
||||||
if (f->subclass < AST_FORMAT_MAX_AUDIO) {
|
if (f->subclass < AST_FORMAT_MAX_AUDIO) {
|
||||||
pred = rtp->lastts + ast_codec_get_samples(f);
|
pred = rtp->lastts + f->samples;
|
||||||
|
|
||||||
/* Re-calculate last TS */
|
/* Re-calculate last TS */
|
||||||
rtp->lastts = rtp->lastts + ms * 8;
|
rtp->lastts = rtp->lastts + ms * 8;
|
||||||
|
|||||||
Reference in New Issue
Block a user