mirror of https://github.com/FFmpeg/FFmpeg.git
The JPEG-2000 decoder and encoder share common luts; the decoder initializes them once, guarded by a dedicated AVOnce, whereas the encoder initializes them always during init. This means that the decoder is not init-threadsafe; in fact there is a potential data race because these luts can be initialized while an active decoder/encoder is using them. Fix this and make the decoder init-threadsafe by making the initialization function guard initialization itself with a dedicated AVOnce. Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>pull/362/head
parent
b43e946b71
commit
3c26773ae2
2 changed files with 11 additions and 10 deletions
Loading…
Reference in new issue