[vlc-commits] core/input: fix potential memory-leak during bookmark parsing

Filip Roséen git at videolan.org
Sun Jun 5 17:02:45 CEST 2016


vlc | branch: master | Filip Roséen <filip at videolabs.io> | Sun Jun  5 16:02:16 2016 +0200| [f4b2930bfc276abf0022954fe2c071754c609878] | committer: Jean-Baptiste Kempf

core/input: fix potential memory-leak during bookmark parsing

Signed-off-by: Thomas Guillem <thomas at gllm.fr>

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

 src/input/input.c |    2 ++
 1 file changed, 2 insertions(+)

diff --git a/src/input/input.c b/src/input/input.c
index afd40d0..325c075 100644
--- a/src/input/input.c
+++ b/src/input/input.c
@@ -428,6 +428,8 @@ static input_thread_t *Create( vlc_object_t *p_parent, input_item_t *p_item,
                      *psz_end = 0;
                      if( !strncmp( psz_start, "name=", 5 ) )
                      {
+                         free( p_seekpoint->psz_name );
+
                          p_seekpoint->psz_name = strdup(psz_start + 5);
                      }
                      else if( !strncmp( psz_start, "time=", 5 ) )



More information about the vlc-commits mailing list