summaryrefslogtreecommitdiff
path: root/libavcodec/dcahuff.c
diff options
context:
space:
mode:
authorAndreas Rheinhardt <andreas.rheinhardt@gmail.com>2020-11-30 23:58:56 +0100
committerAndreas Rheinhardt <andreas.rheinhardt@outlook.com>2021-05-02 05:14:41 +0200
commit7d4f1f4d99a95e30a7d5b85dc591e388b2f9f3bd (patch)
treed441cc73c1effa4aa8074fad349b9507133844d1 /libavcodec/dcahuff.c
parente5bc8b623661db80e854765d7ac359764b0d0760 (diff)
avcodec/dca*: Make decoder init-threadsafe
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@gmail.com>
Diffstat (limited to 'libavcodec/dcahuff.c')
-rw-r--r--libavcodec/dcahuff.c6
1 files changed, 0 insertions, 6 deletions
diff --git a/libavcodec/dcahuff.c b/libavcodec/dcahuff.c
index 0a3eeb4d22..6197ccfe9b 100644
--- a/libavcodec/dcahuff.c
+++ b/libavcodec/dcahuff.c
@@ -1263,12 +1263,8 @@ VLC ff_dca_vlc_rsd;
av_cold void ff_dca_init_vlcs(void)
{
static VLC_TYPE dca_table[30214][2];
- static int vlcs_initialized = 0;
int i, j, k = 0;
- if (vlcs_initialized)
- return;
-
#define DCA_INIT_VLC(vlc, a, b, c, d) \
do { \
vlc.table = &dca_table[vlc_offs[k]]; \
@@ -1331,8 +1327,6 @@ av_cold void ff_dca_init_vlcs(void)
LBR_INIT_VLC(ff_dca_vlc_grid_2, grid_2, 9);
LBR_INIT_VLC(ff_dca_vlc_grid_3, grid_3, 9);
LBR_INIT_VLC(ff_dca_vlc_rsd, rsd, 6);
-
- vlcs_initialized = 1;
}
uint32_t ff_dca_vlc_calc_quant_bits(int *values, uint8_t n, uint8_t sel, uint8_t table)