[FFmpeg-cvslog] avformat/dashdec: Fix leak of representation languages

Andreas Rheinhardt git at videolan.org
Mon Sep 21 06:00:18 EEST 2020


ffmpeg | branch: master | Andreas Rheinhardt <andreas.rheinhardt at gmail.com> | Sat Sep 19 07:01:30 2020 +0200| [f1c3c173c9408085d7b26f3bdd264b426bca314a] | committer: Andreas Rheinhardt

avformat/dashdec: Fix leak of representation languages

These languages are normally freed after having been added as metadata
to their respective AVStreams. Yet if one never reaches said point, they
leak. This can happen as a result of an error when reading the header or
as a result of refreshing the manifests.

Reviewed-by: Steven Liu <lq at chinaffmpeg.org>
Signed-off-by: Andreas Rheinhardt <andreas.rheinhardt at gmail.com>

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=f1c3c173c9408085d7b26f3bdd264b426bca314a
---

 libavformat/dashdec.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/libavformat/dashdec.c b/libavformat/dashdec.c
index ca2c2b5fd2..4d4611ef04 100644
--- a/libavformat/dashdec.c
+++ b/libavformat/dashdec.c
@@ -359,6 +359,7 @@ static void free_representation(struct representation *pls)
     }
 
     av_freep(&pls->url_template);
+    av_freep(&pls->lang);
     av_freep(&pls);
 }
 



More information about the ffmpeg-cvslog mailing list