diff mbox series

[FFmpeg-devel,1/2] avformat/rtsp: av_rescale -> av_rescale_q

Message ID 1605277802-26409-1-git-send-email-lance.lmwang@gmail.com
State Accepted
Commit 5bb313e72328021ed11d4c1032c8dfde13a50a30
Headers show
Series [FFmpeg-devel,1/2] avformat/rtsp: av_rescale -> av_rescale_q | expand

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished

Commit Message

Lance Wang Nov. 13, 2020, 2:30 p.m. UTC
From: Limin Wang <lance.lmwang@gmail.com>

Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
---
 libavformat/rtsp.c | 4 +---
 1 file changed, 1 insertion(+), 3 deletions(-)

Comments

Michael Niedermayer Nov. 13, 2020, 4:49 p.m. UTC | #1
On Fri, Nov 13, 2020 at 10:30:01PM +0800, lance.lmwang@gmail.com wrote:
> From: Limin Wang <lance.lmwang@gmail.com>
> 
> Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
> ---
>  libavformat/rtsp.c | 4 +---
>  1 file changed, 1 insertion(+), 3 deletions(-)

should be ok

thx

[...]
diff mbox series

Patch

diff --git a/libavformat/rtsp.c b/libavformat/rtsp.c
index 5ef2f23..d9832bb 100644
--- a/libavformat/rtsp.c
+++ b/libavformat/rtsp.c
@@ -2247,9 +2247,7 @@  redo:
                     s->start_time_realtime = av_rescale (rtpctx->first_rtcp_ntp_time - (NTP_OFFSET << 32), 1000000, 1LL << 32);
                     if (rtpctx->st) {
                         s->start_time_realtime -=
-                            av_rescale (rtpctx->rtcp_ts_offset,
-                                        (uint64_t) rtpctx->st->time_base.num * 1000000,
-                                                   rtpctx->st->time_base.den);
+                            av_rescale_q (rtpctx->rtcp_ts_offset, rtpctx->st->time_base, AV_TIME_BASE_Q);
                     }
                 }
             }