aboutsummaryrefslogtreecommitdiffstats
path: root/libavcodec/mscc.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>2020-12-02 00:10:13 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@gmail.com>2020-12-10 01:36:16 +0100
commit6a94afbd5bf4aa3ccab12f038e8bbae7ef3973c0 (patch)
treeb4ae496edfcbeb083e928f7cb9c5c4c00bd7c7c8 /libavcodec/mscc.c
parentbdfe51b44f01de89f794a307f0a59941bc0ec9fa (diff)
downloadffmpeg-6a94afbd5bf4aa3ccab12f038e8bbae7ef3973c0.tar.gz
avcodec/snow: Use ff_thread_once() in ff_snow_common_init()
ff_snow_common_init() currently initializes static data every time it is invoked; given that both the Snow encoder and decoder have the FF_CODEC_CAP_INIT_THREADSAFE flag set, this can lead to data races (and therefore undefined behaviour) even though all threads write the same values. This commit fixes this by using ff_thread_once() for the initializations. Reviewed-by: Michael Niedermayer <michael@niedermayer.cc> Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/mscc.c')
0 files changed, 0 insertions, 0 deletions