[FFmpeg-devel] [PATCH 4/5] avcodec/libvorbisenc: Actually set error upon goto error
Andreas Rheinhardt
andreas.rheinhardt at outlook.com
Thu Apr 15 05:04:10 EEST 2021
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at outlook.com>
---
libavcodec/libvorbisenc.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/libavcodec/libvorbisenc.c b/libavcodec/libvorbisenc.c
index b556280a95..061a4e9da7 100644
--- a/libavcodec/libvorbisenc.c
+++ b/libavcodec/libvorbisenc.c
@@ -263,7 +263,8 @@ static av_cold int libvorbis_encode_init(AVCodecContext *avctx)
s->vp = av_vorbis_parse_init(avctx->extradata, avctx->extradata_size);
if (!s->vp) {
av_log(avctx, AV_LOG_ERROR, "invalid extradata\n");
- return ret;
+ ret = AVERROR_UNKNOWN;
+ goto error;
}
avctx->frame_size = LIBVORBIS_FRAME_SIZE;
--
2.27.0
More information about the ffmpeg-devel
mailing list