avformat/utils: free s->pb for image2 as it can be used with and without a file

Signed-off-by: Michael Niedermayer <michaelni@gmx.at>
This commit is contained in:
Michael Niedermayer 2014-09-13 22:56:05 +02:00
parent 89d42da5c6
commit 36ea35bbc0
1 changed files with 1 additions and 1 deletions

View File

@ -3548,7 +3548,7 @@ void avformat_close_input(AVFormatContext **ps)
s = *ps;
pb = s->pb;
if ((s->iformat && s->iformat->flags & AVFMT_NOFILE) ||
if ((s->iformat && strcmp(s->iformat->name, "image2") && s->iformat->flags & AVFMT_NOFILE) ||
(s->flags & AVFMT_FLAG_CUSTOM_IO))
pb = NULL;