aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-05-05 20:50:16 +0200
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-05-10 22:12:02 +0200
commit413ec81ba8303468aca1c7c83bfd1118854987d0 (patch)
tree1cc67e242cafc16237ff4e674c614677ad9fd82d
parentf100a7de5cd15119305aab59b4b3f8f2542ee1c0 (diff)
downloadffmpeg-413ec81ba8303468aca1c7c83bfd1118854987d0.tar.gz
avcodec/pngenc: Mark encoders as init-threadsafe
Initializing zlib in the way we do here is threadsafe, see https://www.zlib.net/zlib_faq.html#faq21 Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
-rw-r--r--libavcodec/pngenc.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/libavcodec/pngenc.c b/libavcodec/pngenc.c
index 831223be63..a398155100 100644
--- a/libavcodec/pngenc.c
+++ b/libavcodec/pngenc.c
@@ -1140,6 +1140,7 @@ const AVCodec ff_png_encoder = {
AV_PIX_FMT_MONOBLACK, AV_PIX_FMT_NONE
},
.priv_class = &pngenc_class,
+ .caps_internal = FF_CODEC_CAP_INIT_THREADSAFE,
};
const AVCodec ff_apng_encoder = {
@@ -1161,4 +1162,5 @@ const AVCodec ff_apng_encoder = {
AV_PIX_FMT_NONE
},
.priv_class = &apngenc_class,
+ .caps_internal = FF_CODEC_CAP_INIT_THREADSAFE,
};