mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-25 00:32:31 +00:00
avcodec/libkvazaar: Increase array size
av_image_copy() expects an array of four pointers according to its
declaration; although it currently only touches pointers that
are actually in use (depending upon the pixel format) this might
change at any time (as has already happened for the linesizes
in d7bc52bf45
).
This fixes a -Wstringop-overflow= warning with GCC 11.2.
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt@outlook.com>
This commit is contained in:
parent
f1c8c25832
commit
b09ea67b40
@ -208,13 +208,19 @@ static int libkvazaar_encode(AVCodecContext *avctx,
|
||||
|
||||
// Copy pixels from frame to input_pic.
|
||||
{
|
||||
uint8_t *dst[4] = {
|
||||
input_pic->data[0],
|
||||
input_pic->data[1],
|
||||
input_pic->data[2],
|
||||
NULL,
|
||||
};
|
||||
int dst_linesizes[4] = {
|
||||
frame->width,
|
||||
frame->width / 2,
|
||||
frame->width / 2,
|
||||
0
|
||||
};
|
||||
av_image_copy(input_pic->data, dst_linesizes,
|
||||
av_image_copy(dst, dst_linesizes,
|
||||
(const uint8_t **)frame->data, frame->linesize,
|
||||
frame->format, frame->width, frame->height);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user