[vlc-commits] demux itml: Add missing terminator element to handler list

Marvin Scholz git at videolan.org
Tue Mar 20 11:19:39 CET 2018


vlc/vlc-3.0 | branch: master | Marvin Scholz <epirat07 at gmail.com> | Tue Mar 20 11:10:07 2018 +0100| [f2c94d2718be785200a20181525ae5eb0884e93d] | committer: Marvin Scholz

demux itml: Add missing terminator element to handler list

The last element of an xml_elem_hnd_t array must be an item where name
is a NULL pointer, else the for-loop will read past the end of the
handler list array.

Fix CD bd213e6a-52cb-4a19-af83-4a8d6de3b8f1

(cherry picked from commit b096bab9d09923e893030f5e4be4ad658195bdfd)
Signed-off-by: Marvin Scholz <epirat07 at gmail.com>

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

 modules/demux/playlist/itml.c | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/modules/demux/playlist/itml.c b/modules/demux/playlist/itml.c
index 36341d36e6..ebeb0eec11 100644
--- a/modules/demux/playlist/itml.c
+++ b/modules/demux/playlist/itml.c
@@ -101,7 +101,10 @@ static int ReadDir( stream_t *p_demux, input_item_node_t *p_subitems )
     }
 
     xml_elem_hnd_t pl_elements[] =
-        { {"dict",    COMPLEX_CONTENT, {.cmplx = parse_plist_dict} } };
+        {
+            {"dict",    COMPLEX_CONTENT, {.cmplx = parse_plist_dict} },
+            {NULL,      UNKNOWN_CONTENT, {NULL} }
+        };
     parse_plist_node( p_demux, p_subitems, NULL, p_xml_reader, "plist",
                       pl_elements );
 



More information about the vlc-commits mailing list