[vlc-devel] [PATCH] Fix crash when podcast item name is missing

Marek Beleščiak marek.belesciak at lunar.sk
Wed Jan 30 02:16:19 CET 2019


There is a case when a null pointer may get passed to vlc_xml_decode(),
which causes a null pointer deference. This commit fixes that.
---
 modules/demux/playlist/podcast.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/modules/demux/playlist/podcast.c b/modules/demux/playlist/podcast.c
index 49367893f7..3251ad3ce4 100644
--- a/modules/demux/playlist/podcast.c
+++ b/modules/demux/playlist/podcast.c
@@ -286,7 +286,8 @@ static int ReadDir( stream_t *p_demux, input_item_node_t *p_subitems )
                     }
 
                     vlc_xml_decode( psz_item_mrl );
-                    vlc_xml_decode( psz_item_name );
+                    if( psz_item_name )
+                       vlc_xml_decode( psz_item_name );
                     p_input = input_item_New( psz_item_mrl, psz_item_name );
                     FREENULL( psz_item_mrl );
                     FREENULL( psz_item_name );
-- 
2.20.1



More information about the vlc-devel mailing list