diff options
author | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-07-23 06:14:32 +0200 |
---|---|---|
committer | Andreas Rheinhardt <andreas.rheinhardt@outlook.com> | 2022-07-31 04:38:11 +0200 |
commit | 5ad29e15908523c423c881bce2aaf62e433169b6 (patch) | |
tree | 5266bb218217089ecdcd0e31050ae66de4a47ef9 /libavcodec/dxv.c | |
parent | a18c372390346d089580a18183115c8f8ef2d1ec (diff) | |
download | ffmpeg-5ad29e15908523c423c881bce2aaf62e433169b6.tar.gz |
avcodec/dxv: Constify slice threads' ptr to main context
Modifying the main context from a slice thread is (usually)
a data race, so it must not happen. So only use a pointer to const
to access the main context.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
Diffstat (limited to 'libavcodec/dxv.c')
-rw-r--r-- | libavcodec/dxv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavcodec/dxv.c b/libavcodec/dxv.c index f36454a9f6..13c028d8ba 100644 --- a/libavcodec/dxv.c +++ b/libavcodec/dxv.c @@ -193,7 +193,7 @@ static int yao_block(uint8_t *plane0, ptrdiff_t stride0, static int decompress_texture_thread(AVCodecContext *avctx, void *arg, int slice, int thread_nb) { - DXVContext *ctx = avctx->priv_data; + const DXVContext *ctx = avctx->priv_data; AVFrame *frame = arg; const uint8_t *d = ctx->tex_data; int w_block = avctx->coded_width / ctx->texture_block_w; |