aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2008-07-19 03:33:42 +0000
committerMichael Niedermayer <michaelni@gmx.at>2008-07-19 03:33:42 +0000
commit7c0efeccfaa6ee925b6802997453dbcb81fa7f59 (patch)
treef60f60d1b56e9fbb42e6f072dfd90bc5944c42c2 /libavcodec
parentf12c4bba7957a3b716ddae3abd4a8aee78a93bb5 (diff)
downloadffmpeg-7c0efeccfaa6ee925b6802997453dbcb81fa7f59.tar.gz
Do not forget marking disposed delayed pics as unused.
Fixes issue335 Originally committed as revision 14296 to svn://svn.ffmpeg.org/ffmpeg/trunk
Diffstat (limited to 'libavcodec')
-rw-r--r--libavcodec/h264.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavcodec/h264.c b/libavcodec/h264.c
index 2b901ea9aa..26d57acb35 100644
--- a/libavcodec/h264.c
+++ b/libavcodec/h264.c
@@ -7866,6 +7866,8 @@ static int decode_frame(AVCodecContext *avctx,
s->avctx->has_b_frames++;
}
+ if(out_of_order || pics > s->avctx->has_b_frames)
+ out->reference &= ~DELAYED_PIC_REF;
if(pics <= s->avctx->has_b_frames || out_of_order)
out = NULL;
@@ -7877,7 +7879,6 @@ static int decode_frame(AVCodecContext *avctx,
if(out){
*data_size = sizeof(AVFrame);
- out->reference &= ~DELAYED_PIC_REF;
h->outputed_poc = out->poc;
}
#endif