summaryrefslogtreecommitdiff
path: root/libavcodec/hqx.c
diff options
context:
space:
mode:
authorVittorio Giovara <vittorio.giovara@gmail.com>2015-04-07 00:40:37 +0200
committerVittorio Giovara <vittorio.giovara@gmail.com>2015-04-24 14:55:11 +0100
commitbb428e00ac158244d6691bf135be404e85b66a8b (patch)
treee7735dde92ec7d1c17f6fff6c686be018ee2a505 /libavcodec/hqx.c
parent43171886e08b6a2f20a1e2f3ecc95a7984b591cd (diff)
hqx: Mark codec as init-thread-safe and init-cleanup
Diffstat (limited to 'libavcodec/hqx.c')
-rw-r--r--libavcodec/hqx.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/libavcodec/hqx.c b/libavcodec/hqx.c
index de460a55b8..11b872cbb3 100644
--- a/libavcodec/hqx.c
+++ b/libavcodec/hqx.c
@@ -523,13 +523,10 @@ static av_cold int hqx_decode_close(AVCodecContext *avctx)
static av_cold int hqx_decode_init(AVCodecContext *avctx)
{
HQXContext *ctx = avctx->priv_data;
- int ret = ff_hqx_init_vlcs(ctx);
- if (ret < 0)
- hqx_decode_close(avctx);
ff_hqxdsp_init(&ctx->hqxdsp);
- return ret;
+ return ff_hqx_init_vlcs(ctx);
}
AVCodec ff_hqx_decoder = {
@@ -542,4 +539,6 @@ AVCodec ff_hqx_decoder = {
.decode = hqx_decode_frame,
.close = hqx_decode_close,
.capabilities = CODEC_CAP_DR1 | CODEC_CAP_SLICE_THREADS,
+ .caps_internal = FF_CODEC_CAP_INIT_THREADSAFE |
+ FF_CODEC_CAP_INIT_CLEANUP,
};