aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/dxva2_av1.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2022-01-04 06:12:27 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2022-01-09 09:32:53 +0100
commit832ead2ec40392e73422f9a9d3ab1f21ea025207 (patch)
tree533eaacbea16cba0b48dda2d1369da09c55d59ac /libavcodec/dxva2_av1.c
parentf0194e860e33cb60a80305eae2262b2e7977c908 (diff)
downloadffmpeg-832ead2ec40392e73422f9a9d3ab1f21ea025207.tar.gz
avcodec/mpeg4videodec: Fix data race when initializing VLCs
Both the MPEG-4 parser as well as the decoder initialized several VLCs. There is a "static int done = 0;" in order to guard against initializing these multiple times, but this does not work when several threads try to initialize these VLCs concurrently, which can happen when initializing several parsers at the same time (they don't use the global lock that is used for codecs without the FF_CODEC_CAP_INIT_THREADSAFE cap; actually, they don't use any lock at all). Since ff_mpeg4_decode_picture_header() now aborts early when called from the parser, it no longer needs to have these VLCs initialized at all. This commit therefore does exactly this. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/dxva2_av1.c')
0 files changed, 0 insertions, 0 deletions