[FFmpeg-devel] [PATCH] avformat/concatdec: avoid NULL dereference when failed to open file.
Nicolas George
george at nsup.org
Thu Jan 29 10:56:54 CET 2015
Le decadi 10 pluviôse, an CCXXIII, Zhang Rui a écrit :
> ---
> libavformat/concatdec.c | 3 +++
> 1 file changed, 3 insertions(+)
>
> diff --git a/libavformat/concatdec.c b/libavformat/concatdec.c
> index e109524..f07cfd7 100644
> --- a/libavformat/concatdec.c
> +++ b/libavformat/concatdec.c
> @@ -482,6 +482,9 @@ static int concat_read_packet(AVFormatContext *avf, AVPacket *pkt)
> ConcatStream *cs;
> AVStream *st;
>
> + if (!cat->avf)
> + return AVERROR(EIO);
> +
> while (1) {
> ret = av_read_frame(cat->avf, pkt);
> if (ret == AVERROR_EOF) {
LGTM, thanks.
Regards,
--
Nicolas George
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20150129/6ff1898d/attachment.asc>
More information about the ffmpeg-devel
mailing list