diff options
author | Andreas Rheinhardt <[email protected]> | 2023-07-17 22:29:21 +0200 |
---|---|---|
committer | Andreas Rheinhardt <[email protected]> | 2023-08-02 18:16:00 +0200 |
commit | 80cc9b81deba0122a531f63b165f661a816d13c5 (patch) | |
tree | 22a782158be31ca1bf23a54b4ef5bd9ae68ac414 | |
parent | 739f24d833f617376b466ece04b6db00ad8fcd56 (diff) |
avcodec/nvdec_(mjpeg|vp8): Constify AVHWAccels
The discrepancy between the actual definition and the declarations
in hwaccels.h is actually UB.
Reviewed-by: Timo Rothenpieler <[email protected]>
Signed-off-by: Andreas Rheinhardt <[email protected]>
-rw-r--r-- | libavcodec/nvdec_mjpeg.c | 2 | ||||
-rw-r--r-- | libavcodec/nvdec_vp8.c | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/libavcodec/nvdec_mjpeg.c b/libavcodec/nvdec_mjpeg.c index fce464c1f8..daaf0072ed 100644 --- a/libavcodec/nvdec_mjpeg.c +++ b/libavcodec/nvdec_mjpeg.c @@ -69,7 +69,7 @@ static int nvdec_mjpeg_frame_params(AVCodecContext *avctx, return ff_nvdec_frame_params(avctx, hw_frames_ctx, 1, 0); } -AVHWAccel ff_mjpeg_nvdec_hwaccel = { +const AVHWAccel ff_mjpeg_nvdec_hwaccel = { .name = "mjpeg_nvdec", .type = AVMEDIA_TYPE_VIDEO, .id = AV_CODEC_ID_MJPEG, diff --git a/libavcodec/nvdec_vp8.c b/libavcodec/nvdec_vp8.c index f174ca430f..3812ef3e1a 100644 --- a/libavcodec/nvdec_vp8.c +++ b/libavcodec/nvdec_vp8.c @@ -90,7 +90,7 @@ static int nvdec_vp8_frame_params(AVCodecContext *avctx, return ff_nvdec_frame_params(avctx, hw_frames_ctx, 3, 0); } -AVHWAccel ff_vp8_nvdec_hwaccel = { +const AVHWAccel ff_vp8_nvdec_hwaccel = { .name = "vp8_nvdec", .type = AVMEDIA_TYPE_VIDEO, .id = AV_CODEC_ID_VP8, |