diff mbox series

[FFmpeg-devel,2/2] libavformat/hls: Free keys

Message ID 20220908224458.23450-2-michael@niedermayer.cc
State Accepted
Commit d32a9f3137c91de86547601a38fea0693c3497f1
Headers show
Series [FFmpeg-devel,1/2] tools/target_dec_fuzzer: Adjust threshold for UTVIDEO | expand

Checks

Context Check Description
andriy/make_x86 success Make finished
andriy/make_fate_x86 success Make fate finished

Commit Message

Michael Niedermayer Sept. 8, 2022, 10:44 p.m. UTC
Fixes: memleak
Fixes: 50703/clusterfuzz-testcase-minimized-ffmpeg_dem_HLS_fuzzer-6399058578636800

Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
---
 libavformat/hls.c | 1 +
 1 file changed, 1 insertion(+)

Comments

Steven Liu Sept. 9, 2022, 3:21 a.m. UTC | #1
Michael Niedermayer <michael@niedermayer.cc> 于2022年9月9日周五 06:45写道:
>
> Fixes: memleak
> Fixes: 50703/clusterfuzz-testcase-minimized-ffmpeg_dem_HLS_fuzzer-6399058578636800
>
> Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
> Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
> ---
>  libavformat/hls.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/libavformat/hls.c b/libavformat/hls.c
> index 3dc7bd39309..e622425e801 100644
> --- a/libavformat/hls.c
> +++ b/libavformat/hls.c
> @@ -250,6 +250,7 @@ static void free_init_section_list(struct playlist *pls)
>  {
>      int i;
>      for (i = 0; i < pls->n_init_sections; i++) {
> +        av_freep(&pls->init_sections[i]->key);
>          av_freep(&pls->init_sections[i]->url);
>          av_freep(&pls->init_sections[i]);
>      }
> --
> 2.17.1
>
> _______________________________________________
> 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
Michael Niedermayer Sept. 10, 2022, 4:04 p.m. UTC | #2
On Fri, Sep 09, 2022 at 11:21:38AM +0800, Steven Liu wrote:
> Michael Niedermayer <michael@niedermayer.cc> 于2022年9月9日周五 06:45写道:
> >
> > Fixes: memleak
> > Fixes: 50703/clusterfuzz-testcase-minimized-ffmpeg_dem_HLS_fuzzer-6399058578636800
> >
> > Found-by: continuous fuzzing process https://github.com/google/oss-fuzz/tree/master/projects/ffmpeg
> > Signed-off-by: Michael Niedermayer <michael@niedermayer.cc>
> > ---
> >  libavformat/hls.c | 1 +
> >  1 file changed, 1 insertion(+)
> >
> > diff --git a/libavformat/hls.c b/libavformat/hls.c
> > index 3dc7bd39309..e622425e801 100644
> > --- a/libavformat/hls.c
> > +++ b/libavformat/hls.c
> > @@ -250,6 +250,7 @@ static void free_init_section_list(struct playlist *pls)
> >  {
> >      int i;
> >      for (i = 0; i < pls->n_init_sections; i++) {
> > +        av_freep(&pls->init_sections[i]->key);
> >          av_freep(&pls->init_sections[i]->url);
> >          av_freep(&pls->init_sections[i]);
> >      }
> > --
> > 2.17.1
> >
> > _______________________________________________
> > 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

will apply

thx

[...]
diff mbox series

Patch

diff --git a/libavformat/hls.c b/libavformat/hls.c
index 3dc7bd39309..e622425e801 100644
--- a/libavformat/hls.c
+++ b/libavformat/hls.c
@@ -250,6 +250,7 @@  static void free_init_section_list(struct playlist *pls)
 {
     int i;
     for (i = 0; i < pls->n_init_sections; i++) {
+        av_freep(&pls->init_sections[i]->key);
         av_freep(&pls->init_sections[i]->url);
         av_freep(&pls->init_sections[i]);
     }