[FFmpeg-cvslog] avformat/utils: inform the user if the protocol cannot be determined
Michael Niedermayer
git at videolan.org
Wed Jul 15 04:10:06 CEST 2015
ffmpeg | branch: master | Michael Niedermayer <michael at niedermayer.cc> | Wed Jul 15 03:44:00 2015 +0200| [90dd6ad22cee78ef8d8de27e30839f99e69a7909] | committer: Michael Niedermayer
avformat/utils: inform the user if the protocol cannot be determined
Assuming the wrong protocol can lead to suboptimal seeking performance
Signed-off-by: Michael Niedermayer <michael at niedermayer.cc>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=90dd6ad22cee78ef8d8de27e30839f99e69a7909
---
libavformat/utils.c | 7 +++++++
1 file changed, 7 insertions(+)
diff --git a/libavformat/utils.c b/libavformat/utils.c
index 1690178..bcd3c52 100644
--- a/libavformat/utils.c
+++ b/libavformat/utils.c
@@ -1789,6 +1789,13 @@ void ff_configure_buffers_for_index(AVFormatContext *s, int64_t time_tolerance)
//We could use URLProtocol flags here but as many user applications do not use URLProtocols this would be unreliable
const char *proto = avio_find_protocol_name(s->filename);
+ if (!proto) {
+ av_log(s, AV_LOG_INFO,
+ "Protocol name not provided, cannot determine if input is local or "
+ "a network protocol, buffers and access patterns cannot be configured "
+ "optimally without knowing the protocol\n");
+ }
+
if (proto && !(strcmp(proto, "file") && strcmp(proto, "pipe") && strcmp(proto, "cache")))
return;
More information about the ffmpeg-cvslog
mailing list