From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org [79.124.17.100]) by master.gitmailbox.com (Postfix) with ESMTP id 66E33464DA for ; Sat, 19 Aug 2023 11:13:25 +0000 (UTC) Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id C243668C59A; Sat, 19 Aug 2023 14:13:22 +0300 (EEST) Received: from btbn.de (btbn.de [136.243.74.85]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id A112B68C49C for ; Sat, 19 Aug 2023 14:13:16 +0300 (EEST) Received: from [authenticated] by btbn.de (Postfix) with ESMTPSA id 02F691715BE for ; Sat, 19 Aug 2023 13:13:13 +0200 (CEST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=rothenpieler.org; s=mail; t=1692443594; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=gmSiwUIxXugUcsCtLUtcI9FYluP6BOYLIFjsP6Zp4Xo=; b=kItMe5rjJSL3mE5HuJQ9+RQEWnzPR+0Xchqj6uqWc9hxJkiHk4zThuvqCsyghGYNj2ZKaj o14wg+B3AP92Z9I42JufZ5uRRuh7GImE4lZYJzurAQLUo9LMFs3m8LnuH+Gc783KL4vBXE OheJFDgH7Zdmsn3gtbJW6ht/DBsSDxuZO3OrndMSyBLwXJJfFPg4NvGnnrUs/Eqbf5qflM JMDr2a16qqUnaiEGu0xj4PpbXeP4dgbze1JvAz4EHLtjnpblGSfEWveB3kc/FV5dDB+y1N uhjjo8gs0nkOjtB4Hd8SecUa6/hKAjf/QkrYcBjgromuPmr+0sZkICKN7nPAUw== Message-ID: <57ffbb32-1d0d-0c7c-bf00-e77aeaaa3179@rothenpieler.org> Date: Sat, 19 Aug 2023 13:13:12 +0200 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:102.0) Gecko/20100101 Thunderbird/102.14.0 To: ffmpeg-devel@ffmpeg.org References: <20230815205330.56868-1-timo@rothenpieler.org> Content-Language: en-US From: Timo Rothenpieler In-Reply-To: <20230815205330.56868-1-timo@rothenpieler.org> Subject: Re: [FFmpeg-devel] [PATCH] avformat/hls: reset the playlist init segment on seek 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 Content-Transfer-Encoding: 7bit Content-Type: text/plain; charset="us-ascii"; Format="flowed" Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" Archived-At: List-Archive: List-Post: On 15.08.2023 22:53, Timo Rothenpieler wrote: > The mp4 demuxer gets very upset when it gets flushed and not re-fed this > data. > --- > libavformat/hls.c | 3 +++ > 1 file changed, 3 insertions(+) > > diff --git a/libavformat/hls.c b/libavformat/hls.c > index 2a2fe28a54..c625e30291 100644 > --- a/libavformat/hls.c > +++ b/libavformat/hls.c > @@ -2506,6 +2506,9 @@ static int hls_read_seek(AVFormatContext *s, int stream_index, > /* Flush the packet queue of the subdemuxer. */ > ff_read_frame_flush(pls->ctx); > > + /* Reset the init segment so it's re-fetched and served appropiately */ > + pls->cur_init_section = NULL; > + > pls->seek_timestamp = seek_timestamp; > pls->seek_flags = flags; > Would appreciate some quick review on this, since I'm not super familiar with the HLS code. It works fine and looks correct to me though, so if nobody does, I'll apply this in a couple days. _______________________________________________ ffmpeg-devel mailing list ffmpeg-devel@ffmpeg.org https://ffmpeg.org/mailman/listinfo/ffmpeg-devel To unsubscribe, visit link above, or email ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".