From patchwork Tue Jul 27 14:48:08 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Nicolas George X-Patchwork-Id: 29067 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a11:4023:0:0:0:0 with SMTP id ky35csp4920043pxb; Tue, 27 Jul 2021 07:49:27 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwEiNs3ZEYL3kltWiizPg9x7gKSrRpUU3gTy4DbfvSB/I/Tdcz2Z/dtPhLMzFjztGM9I8/p X-Received: by 2002:a05:6402:d67:: with SMTP id ec39mr7300805edb.117.1627397367113; Tue, 27 Jul 2021 07:49:27 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1627397367; cv=none; d=google.com; s=arc-20160816; b=NorB8APVjyNQF/Hld+Jlw5IbCdSnmSMAmTw8qzolLfBRAszVdf7vJxEaIteoln4YHD j7ZUNtMqyyLhPtPgFSA2cQdLwDgVZWG6rQ/5N8pjoTdf9acnJ7peRdYk8uiyS/KknnGQ dBumaE+9YtFlEcfNVHk4wQKpBKmPTJlZ68mgZW0FSaB+BYZo8iCrQi+rcOPPvmY2xShu HYh96OcM8bC8uAzfxcUyF/hi8w0xfq5MGRKC65+knwS/wwaXWBWKmsdqNLMODi8LoptF 9/+5LNU1wOY1ZzxP6CFp/S7AKCDThyp74pFW4MxpK6tlYEz5Bi0Jo4lIm7SKLLxBHYX8 q7Kg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:reply-to:list-subscribe :list-help:list-post:list-archive:list-unsubscribe:list-id :precedence:subject:mime-version:references:in-reply-to:message-id :date:to:from:delivered-to; bh=Q32dN1PXccBcuEs+atmU5/TwUiiauLqnzg2B0vheXo4=; b=XSV5zkGCMnpFEVE3ixAVrvUjSvAigv0F1sR6WN/EidXbTbIDHICeLDRuN95/cfAMPL 2M3eU3NjNa9O1tR+lFhfeg9J8unoyZS/yWE8rZ/obXaOyJfKbirQpicEYGq5BpVOp/Tq 7Rz8jz0nAWTl28RcEnDdxm/oLvEcWoBOa8+a/RkxgrrueCPU1sOjKHfjvucBk71Wq40k ZqN/3RcdvEc+4YKTD6L8l8+mQOStJsQUxp/1GV4Rp/aLXZfwohmyEqRDUCQ2E0p/pV4Y v3JhQXXDYB1WDfSyOsFSertjz6URcwGy4JBBYn/yMZlmG8TumE96uYhNW0H4jerB0ak9 UtFQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id r18si3291497edv.355.2021.07.27.07.49.26; Tue, 27 Jul 2021 07:49:27 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A4F8268A0F9; Tue, 27 Jul 2021 17:48:29 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from nef.ens.fr (nef2.ens.fr [129.199.96.40]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id D0BD568818E for ; Tue, 27 Jul 2021 17:48:19 +0300 (EEST) X-ENS-nef-client: 129.199.129.80 ( name = phare.normalesup.org ) Received: from phare.normalesup.org (phare.normalesup.org [129.199.129.80]) by nef.ens.fr (8.14.4/1.01.28121999) with ESMTP id 16REmJYk026211 for ; Tue, 27 Jul 2021 16:48:19 +0200 Received: by phare.normalesup.org (Postfix, from userid 1001) id 0F6ADE0027; Tue, 27 Jul 2021 16:48:19 +0200 (CEST) From: Nicolas George To: ffmpeg-devel@ffmpeg.org Date: Tue, 27 Jul 2021 16:48:08 +0200 Message-Id: <20210727144813.452917-6-george@nsup.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210727144813.452917-1-george@nsup.org> References: <20210727144813.452917-1-george@nsup.org> MIME-Version: 1.0 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.4.3 (nef.ens.fr [129.199.96.32]); Tue, 27 Jul 2021 16:48:19 +0200 (CEST) Subject: [FFmpeg-devel] [PATCH 05/10] lavf/avio: treat fs: the same way as file:. X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 57lhLSJX4rfC Signed-off-by: Nicolas George --- libavformat/avio.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) 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;