diff mbox series

[FFmpeg-devel,2/3] avcodec/alac: Add FF_CODEC_CAP_INIT_CLEANUP

Message ID 1590845462-9163-2-git-send-email-lance.lmwang@gmail.com
State Accepted
Headers show
Series [FFmpeg-devel,1/3] avutil/dict: av_realloc -> av_realloc_array() | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Lance Wang May 30, 2020, 1:31 p.m. UTC
From: Limin Wang <lance.lmwang@gmail.com>

Signed-off-by: Limin Wang <lance.lmwang@gmail.com>
---
 libavcodec/alac.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/libavcodec/alac.c b/libavcodec/alac.c
index 82689da..3b41373 100644
--- a/libavcodec/alac.c
+++ b/libavcodec/alac.c
@@ -511,7 +511,6 @@  static int allocate_buffers(ALACContext *alac)
     }
     return 0;
 buf_alloc_fail:
-    alac_decode_close(alac->avctx);
     return AVERROR(ENOMEM);
 }
 
@@ -625,5 +624,6 @@  AVCodec ff_alac_decoder = {
     .close          = alac_decode_close,
     .decode         = alac_decode_frame,
     .capabilities   = AV_CODEC_CAP_DR1 | AV_CODEC_CAP_FRAME_THREADS,
+    .caps_internal  = FF_CODEC_CAP_INIT_CLEANUP,
     .priv_class     = &alac_class
 };