diff mbox series

[FFmpeg-devel,05/10] lavf/avio: treat fs: the same way as file:.

Message ID 20210727144813.452917-6-george@nsup.org
State New
Headers show
Series [FFmpeg-devel,01/10] lavu/internal: add hex to int functions. | expand

Checks

Context Check Description
andriy/x86_make success Make finished
andriy/x86_make_fate success Make fate finished
andriy/PPC64_make success Make finished
andriy/PPC64_make_fate success Make fate finished

Commit Message

Nicolas George July 27, 2021, 2:48 p.m. UTC
Signed-off-by: Nicolas George <george@nsup.org>
---
 libavformat/avio.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/libavformat/avio.c b/libavformat/avio.c
index 4846bbd8c6..13bba52e73 100644
--- a/libavformat/avio.c
+++ b/libavformat/avio.c
@@ -217,7 +217,9 @@  int ffurl_connect(URLContext *uc, AVDictionary **options)
     uc->is_connected = 1;
     /* We must be careful here as ffurl_seek() could be slow,
      * for example for http */
-    if ((uc->flags & AVIO_FLAG_WRITE) || !strcmp(uc->prot->name, "file"))
+    if ((uc->flags & AVIO_FLAG_WRITE) ||
+        !strcmp(uc->prot->name, "file") ||
+        !strcmp(uc->prot->name, "fs"))
         if (!uc->is_streamed && ffurl_seek(uc, 0, SEEK_SET) < 0)
             uc->is_streamed = 1;
     return 0;