[FFmpeg-cvslog] ffplay: Avoid directly accessing AVFrame fields that differ between forks.

Michael Niedermayer git at videolan.org
Mon Dec 5 05:04:39 CET 2011


ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Sat Dec  3 21:21:30 2011 +0100| [406e9647a08701d6b51f2e8abcb0166c74230917] | committer: Michael Niedermayer

ffplay: Avoid directly accessing AVFrame fields that differ between forks.

Signed-off-by: Michael Niedermayer <michaelni at gmx.at>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=406e9647a08701d6b51f2e8abcb0166c74230917
---

 ffplay.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)

diff --git a/ffplay.c b/ffplay.c
index 51753e2..c1fe937 100644
--- a/ffplay.c
+++ b/ffplay.c
@@ -1486,7 +1486,7 @@ static int get_video_frame(VideoState *is, AVFrame *frame, int64_t *pts, AVPacke
         int ret = 1;
 
         if (decoder_reorder_pts == -1) {
-            *pts = frame->best_effort_timestamp;
+            *pts = *(int64_t*)av_opt_ptr(avcodec_get_frame_class(), frame, "best_effort_timestamp");
         } else if (decoder_reorder_pts) {
             *pts = frame->pkt_pts;
         } else {



More information about the ffmpeg-cvslog mailing list