aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorReimar Döffinger <Reimar.Doeffinger@gmx.de>2011-06-22 18:25:49 +0200
committerReimar Döffinger <Reimar.Doeffinger@gmx.de>2011-06-22 21:20:24 +0200
commit3fedb3e65c6595c4fd78b03ed9b0d83cf257062c (patch)
treec5cf951326ee83fa4a30db9bcd5aeaa9bbc1d3f8
parent1986380df2caaa663f63d0a3b9f0413a3d862757 (diff)
downloadffmpeg-3fedb3e65c6595c4fd78b03ed9b0d83cf257062c.tar.gz
Revert needless API change in 05e84c95.
When providing a custom AVIOContex for a AVFMT_NOFILE format only print a warning instead of erroring out. This allows the code to work with older MPlayer versions that just always set pb out of laziness. Signed-off-by: Reimar Döffinger <Reimar.Doeffinger@gmx.de>
-rw-r--r--libavformat/utils.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/libavformat/utils.c b/libavformat/utils.c
index aebf8f68c0..b610276844 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -661,7 +661,8 @@ static int init_input(AVFormatContext *s, const char *filename)
if (!s->iformat)
return av_probe_input_buffer(s->pb, &s->iformat, filename, s, 0, 0);
else if (s->iformat->flags & AVFMT_NOFILE)
- return AVERROR(EINVAL);
+ av_log(s, AV_LOG_WARNING, "Custom AVIOContext makes no sense and "
+ "will be ignored with AVFMT_NOFILE format.\n");
return 0;
}