[FFmpeg-cvslog] avformat/hlsproto: Use av_freep, to avoid leaving stale pointers in memory
Michael Niedermayer
git at videolan.org
Tue Jan 6 15:28:42 CET 2015
ffmpeg | branch: master | Michael Niedermayer <michaelni at gmx.at> | Tue Jan 6 12:52:55 2015 +0100| [59ca6e2586949c252fa4b9e4562e9d8c5bf6b38c] | committer: Michael Niedermayer
avformat/hlsproto: Use av_freep, to avoid leaving stale pointers in memory
Signed-off-by: Michael Niedermayer <michaelni at gmx.at>
> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=59ca6e2586949c252fa4b9e4562e9d8c5bf6b38c
---
libavformat/hlsproto.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/libavformat/hlsproto.c b/libavformat/hlsproto.c
index a569e92..788562a 100644
--- a/libavformat/hlsproto.c
+++ b/libavformat/hlsproto.c
@@ -80,7 +80,7 @@ static void free_segment_list(HLSContext *s)
{
int i;
for (i = 0; i < s->n_segments; i++)
- av_free(s->segments[i]);
+ av_freep(&s->segments[i]);
av_freep(&s->segments);
s->n_segments = 0;
}
@@ -89,7 +89,7 @@ static void free_variant_list(HLSContext *s)
{
int i;
for (i = 0; i < s->n_variants; i++)
- av_free(s->variants[i]);
+ av_freep(&s->variants[i]);
av_freep(&s->variants);
s->n_variants = 0;
}
More information about the ffmpeg-cvslog
mailing list