summaryrefslogtreecommitdiff
path: root/libavcodec/smacker.c
diff options
context:
space:
mode:
authorStefano Sabatini <stefano.sabatini-lala@poste.it>2011-04-26 11:37:36 +0200
committerRonald S. Bultje <rsbultje@gmail.com>2011-04-27 07:41:59 -0700
commit4f2954e2327c211f3fbe20b84f4881e1f8df1528 (patch)
treea6c0e1e7324ac182981bbd447e2aa344c4370043 /libavcodec/smacker.c
parent5eef4afb9a5c637229469036285fa9a334f6f7d4 (diff)
smacker: remove unnecessary call to avctx->release_buffer in decode_frame()
The release_buffer was cleaning the provided frame, thus causing the successive call to avctx->reget_buffer() to allocate a new frame. In case the returned frame was not the same one previously returned but a new one with different data, it resulted in artifacts. Signed-off-by: Ronald S. Bultje <rsbultje@gmail.com>
Diffstat (limited to 'libavcodec/smacker.c')
-rw-r--r--libavcodec/smacker.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/libavcodec/smacker.c b/libavcodec/smacker.c
index 3a97b720a5..aef5e2502b 100644
--- a/libavcodec/smacker.c
+++ b/libavcodec/smacker.c
@@ -360,8 +360,6 @@ static int decode_frame(AVCodecContext *avctx, void *data, int *data_size, AVPac
if(buf_size <= 769)
return 0;
- if(smk->pic.data[0])
- avctx->release_buffer(avctx, &smk->pic);
smk->pic.reference = 1;
smk->pic.buffer_hints = FF_BUFFER_HINTS_VALID | FF_BUFFER_HINTS_PRESERVE | FF_BUFFER_HINTS_REUSABLE;