From patchwork Wed Aug 3 18:55:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Niedermayer X-Patchwork-Id: 79 Delivered-To: ffmpegpatchwork@gmail.com Received: by 10.103.140.67 with SMTP id o64csp840285vsd; Wed, 3 Aug 2016 11:59:37 -0700 (PDT) X-Received: by 10.194.149.176 with SMTP id ub16mr62232403wjb.54.1470250776954; Wed, 03 Aug 2016 11:59:36 -0700 (PDT) Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id dw15si9419132wjb.134.2016.08.03.11.59.36; Wed, 03 Aug 2016 11:59:36 -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 8429168A261; Wed, 3 Aug 2016 21:59:26 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from vie01a-dmta-pe02-2.mx.upcmail.net (vie01a-dmta-pe02-2.mx.upcmail.net [62.179.121.158]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 2230168A21C for ; Wed, 3 Aug 2016 21:58:13 +0300 (EEST) Received: from [172.31.216.43] (helo=vie01a-pemc-psmtp-pe01) by vie01a-dmta-pe02.mx.upcmail.net with esmtp (Exim 4.87) (envelope-from ) id 1bV1Mx-0003K7-7Z for ffmpeg-devel@ffmpeg.org; Wed, 03 Aug 2016 20:58:19 +0200 Received: from localhost ([213.47.41.20]) by vie01a-pemc-psmtp-pe01 with SMTP @ mailcloud.upcmail.net id SiyJ1t0090S5wYM01iyKW0; Wed, 03 Aug 2016 20:58:19 +0200 X-SourceIP: 213.47.41.20 From: Michael Niedermayer To: FFmpeg development discussions and patches Date: Wed, 3 Aug 2016 20:55:22 +0200 Message-Id: <20160803185523.27767-2-michael@niedermayer.cc> X-Mailer: git-send-email 2.9.2 In-Reply-To: <20160803185523.27767-1-michael@niedermayer.cc> References: <20160803185523.27767-1-michael@niedermayer.cc> Subject: [FFmpeg-devel] [PATCH 2/3] avformat/hlsenc: Use AV_FRAME_FILENAME_FLAGS_MULTIPLE, support tee: X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.20 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 MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Signed-off-by: Michael Niedermayer --- libavformat/hlsenc.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/libavformat/hlsenc.c b/libavformat/hlsenc.c index 5dc518d..9f076ba 100644 --- a/libavformat/hlsenc.c +++ b/libavformat/hlsenc.c @@ -561,14 +561,16 @@ static int hls_start(AVFormatContext *s) } av_free(fn_copy); } - } else if (av_get_frame_filename(oc->filename, sizeof(oc->filename), - c->basename, c->wrap ? c->sequence % c->wrap : c->sequence) < 0) { + } else if (av_get_frame_filename2(oc->filename, sizeof(oc->filename), + c->basename, c->wrap ? c->sequence % c->wrap : c->sequence, + AV_FRAME_FILENAME_FLAGS_MULTIPLE) < 0) { av_log(oc, AV_LOG_ERROR, "Invalid segment filename template '%s' you can try use -use_localtime 1 with it\n", c->basename); return AVERROR(EINVAL); } if( c->vtt_basename) { - if (av_get_frame_filename(vtt_oc->filename, sizeof(vtt_oc->filename), - c->vtt_basename, c->wrap ? c->sequence % c->wrap : c->sequence) < 0) { + if (av_get_frame_filename2(vtt_oc->filename, sizeof(vtt_oc->filename), + c->vtt_basename, c->wrap ? c->sequence % c->wrap : c->sequence, + AV_FRAME_FILENAME_FLAGS_MULTIPLE) < 0) { av_log(vtt_oc, AV_LOG_ERROR, "Invalid segment filename template '%s'\n", c->vtt_basename); return AVERROR(EINVAL); }