ffmpeg | branch: master | James Almer <jamr...@gmail.com> | Tue Jan 7 16:08:11 2025 -0300| [692ce2503e805bd95c1d9d0b40491a5b77fbb6f7] | committer: James Almer
avformat/flvdec: initialize ret in flv_read_packet() to AVERROR_BUG This will ensure any future goto leave that may be added doesn't accidentally forget to set ret to some proper value. Reviewed-by: Timo Rothenpieler <t...@rothenpieler.org> Signed-off-by: James Almer <jamr...@gmail.com> > http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=692ce2503e805bd95c1d9d0b40491a5b77fbb6f7 --- libavformat/flvdec.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/libavformat/flvdec.c b/libavformat/flvdec.c index 15494d26cd..7d56c3e403 100644 --- a/libavformat/flvdec.c +++ b/libavformat/flvdec.c @@ -1280,7 +1280,7 @@ static int flv_update_video_color_info(AVFormatContext *s, AVStream *st) static int flv_read_packet(AVFormatContext *s, AVPacket *pkt) { FLVContext *flv = s->priv_data; - int ret = 0, i, size, flags; + int ret = AVERROR_BUG, i, size, flags; int res = 0; enum FlvTagType type; int stream_type = -1; @@ -1795,6 +1795,7 @@ next_track: } } + ret = 0; leave: last = avio_rb32(s->pb); if (!flv->trust_datasize) { _______________________________________________ ffmpeg-cvslog mailing list ffmpeg-cvslog@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-cvslog To unsubscribe, visit link above, or email ffmpeg-cvslog-requ...@ffmpeg.org with subject "unsubscribe".