mirror of
https://git.ffmpeg.org/ffmpeg.git
synced 2024-12-20 06:20:40 +00:00
mpjpgdec: free AVIOContext leak on early probe fail
This commit is contained in:
parent
925b80d640
commit
caf7be30b1
@ -88,7 +88,7 @@ static int mpjpeg_read_probe(AVProbeData *p)
|
||||
return AVERROR(ENOMEM);
|
||||
|
||||
if (p->buf_size < 2 || p->buf[0] != '-' || p->buf[1] != '-')
|
||||
return 0;
|
||||
goto end;
|
||||
|
||||
while (!pb->eof_reached) {
|
||||
ret = get_line(pb, line, sizeof(line));
|
||||
@ -101,7 +101,7 @@ static int mpjpeg_read_probe(AVProbeData *p)
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
end:
|
||||
av_free(pb);
|
||||
|
||||
return ret;
|
||||
|
Loading…
Reference in New Issue
Block a user