diff options
author | Michael Niedermayer <michaelni@gmx.at> | 2014-12-10 14:34:46 +0100 |
---|---|---|
committer | Michael Niedermayer <michaelni@gmx.at> | 2014-12-10 14:46:39 +0100 |
commit | ae93965359e71c1f88ba170f8efd6a198344c235 (patch) | |
tree | 65f34365e7c6cd30e60ed8c95b4e2e9a96d7a14f | |
parent | 52a17972defa118705a4020a6d0bb3ad277df819 (diff) | |
download | ffmpeg-ae93965359e71c1f88ba170f8efd6a198344c235.tar.gz |
avcodec/hevc_refs: fix potential use of uninitialized min_idx
Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r-- | libavcodec/hevc_refs.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/hevc_refs.c b/libavcodec/hevc_refs.c index b3a97871d5..92196a1ee9 100644 --- a/libavcodec/hevc_refs.c +++ b/libavcodec/hevc_refs.c @@ -173,7 +173,7 @@ int ff_hevc_output_frame(HEVCContext *s, AVFrame *out, int flush) if ((frame->flags & HEVC_FRAME_FLAG_OUTPUT) && frame->sequence == s->seq_output) { nb_output++; - if (frame->poc < min_poc) { + if (frame->poc < min_poc || nb_output == 1) { min_poc = frame->poc; min_idx = i; } |