mirror of
https://github.com/librempeg/librempeg
synced 2024-11-22 18:49:58 +00:00
avcodec/mediacodecenc: Fix access of uninitialized value
When crop is skipped, av_strlcatf will access `str` which isn't initialized properly. Signed-off-by: Zhao Zhili <zhilizhao@tencent.com> Signed-off-by: Paul B Mahol <onemda@gmail.com>
This commit is contained in:
parent
bc5c3d0b20
commit
b8fa549227
@ -134,7 +134,7 @@ static int extract_extradata_support(AVCodecContext *avctx)
|
||||
static int mediacodec_init_bsf(AVCodecContext *avctx)
|
||||
{
|
||||
MediaCodecEncContext *s = avctx->priv_data;
|
||||
char str[128];
|
||||
char str[128] = {0};
|
||||
int ret;
|
||||
int crop_right = s->width - avctx->width;
|
||||
int crop_bottom = s->height - avctx->height;
|
||||
|
Loading…
Reference in New Issue
Block a user