mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2026-06-11 08:13:06 +00:00
avcodec/g728dec: init missing sample rate
Fixes: BAD BUILD: fuzzing /tmp/not-out/tmp0d_svy0e/ffmpeg_AV_CODEC_ID_G728_DEC_fuzzer with afl-fuzz failed Found-by: OSS-Fuzz Signed-off-by: Kacper Michajłow <kasper93@gmail.com>
This commit is contained in:
@@ -96,6 +96,8 @@ static av_cold int g728_decode_init(AVCodecContext *avctx)
|
||||
s->sbg[NSBGSZ - 1 -i] = -GOFF;
|
||||
|
||||
avctx->sample_fmt = AV_SAMPLE_FMT_FLT;
|
||||
if (!avctx->sample_rate)
|
||||
avctx->sample_rate = 8000;
|
||||
|
||||
av_channel_layout_uninit(&avctx->ch_layout);
|
||||
avctx->ch_layout = (AVChannelLayout)AV_CHANNEL_LAYOUT_MONO;
|
||||
|
||||
Reference in New Issue
Block a user