diff mbox series

[FFmpeg-devel,2/3] lavf/hls: enable custom interrup callback in sub-demuxer

Message ID 1595073385-29007-2-git-send-email-mypopydev@gmail.com
State Accepted
Commit 4239a8c9831a0054af47400aaf78167178b97197
Headers show
Series [FFmpeg-devel,1/3] doc/http: Update HTTP protocol options | expand

Checks

Context Check Description
andriy/default pending
andriy/make success Make finished
andriy/make_fate success Make fate finished

Commit Message

Jun Zhao July 18, 2020, 11:56 a.m. UTC
From: Jun Zhao <barryjzhao@tencent.com>

Enable the custom callback in sub-demuxer

Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
---
 libavformat/hls.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Steven Liu July 20, 2020, 2:17 a.m. UTC | #1
Jun Zhao <mypopydev@gmail.com> 于2020年7月18日周六 下午7:56写道:
>
> From: Jun Zhao <barryjzhao@tencent.com>
>
> Enable the custom callback in sub-demuxer
>
> Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
> ---
>  libavformat/hls.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/libavformat/hls.c b/libavformat/hls.c
> index ba17c4e..cf0b71d 100644
> --- a/libavformat/hls.c
> +++ b/libavformat/hls.c
> @@ -1984,6 +1984,7 @@ static int hls_read_header(AVFormatContext *s)
>                            read_data, NULL, NULL);
>          pls->ctx->probesize = s->probesize > 0 ? s->probesize : 1024 * 4;
>          pls->ctx->max_analyze_duration = s->max_analyze_duration > 0 ? s->max_analyze_duration : 4 * AV_TIME_BASE;
> +        pls->ctx->interrupt_callback = s->interrupt_callback;
>          url = av_strdup(pls->segments[0]->url);
>          ret = av_probe_input_buffer(&pls->pb, &in_fmt, url, NULL, 0, 0);
>          av_free(url);
> --
> 2.7.4
>
> _______________________________________________
> 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".


LGTM


Thanks
Steven
Jun Zhao July 20, 2020, 11:28 a.m. UTC | #2
On Mon, Jul 20, 2020 at 10:18 AM Steven Liu <lingjiujianke@gmail.com> wrote:
>
> Jun Zhao <mypopydev@gmail.com> 于2020年7月18日周六 下午7:56写道:
> >
> > From: Jun Zhao <barryjzhao@tencent.com>
> >
> > Enable the custom callback in sub-demuxer
> >
> > Signed-off-by: Jun Zhao <barryjzhao@tencent.com>
> > ---
> >  libavformat/hls.c | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/libavformat/hls.c b/libavformat/hls.c
> > index ba17c4e..cf0b71d 100644
> > --- a/libavformat/hls.c
> > +++ b/libavformat/hls.c
> > @@ -1984,6 +1984,7 @@ static int hls_read_header(AVFormatContext *s)
> >                            read_data, NULL, NULL);
> >          pls->ctx->probesize = s->probesize > 0 ? s->probesize : 1024 * 4;
> >          pls->ctx->max_analyze_duration = s->max_analyze_duration > 0 ? s->max_analyze_duration : 4 * AV_TIME_BASE;
> > +        pls->ctx->interrupt_callback = s->interrupt_callback;
> >          url = av_strdup(pls->segments[0]->url);
> >          ret = av_probe_input_buffer(&pls->pb, &in_fmt, url, NULL, 0, 0);
> >          av_free(url);
> > --
> > 2.7.4
> >
> > _______________________________________________
> > 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".
>
>
> LGTM
>
Pushed, thx
diff mbox series

Patch

diff --git a/libavformat/hls.c b/libavformat/hls.c
index ba17c4e..cf0b71d 100644
--- a/libavformat/hls.c
+++ b/libavformat/hls.c
@@ -1984,6 +1984,7 @@  static int hls_read_header(AVFormatContext *s)
                           read_data, NULL, NULL);
         pls->ctx->probesize = s->probesize > 0 ? s->probesize : 1024 * 4;
         pls->ctx->max_analyze_duration = s->max_analyze_duration > 0 ? s->max_analyze_duration : 4 * AV_TIME_BASE;
+        pls->ctx->interrupt_callback = s->interrupt_callback;
         url = av_strdup(pls->segments[0]->url);
         ret = av_probe_input_buffer(&pls->pb, &in_fmt, url, NULL, 0, 0);
         av_free(url);