Commit 7f74ae29 authored by Pierre Ynard's avatar Pierre Ynard

luasd: handle memory error on probing

parent ec80ab80
...@@ -621,10 +621,12 @@ int vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L, ...@@ -621,10 +621,12 @@ int vlclua_playlist_add_internal( vlc_object_t *p_this, lua_State *L,
static int vlc_sd_probe_Open( vlc_object_t *obj ) static int vlc_sd_probe_Open( vlc_object_t *obj )
{ {
vlc_dictionary_t name_d; vlc_dictionary_t name_d;
vlc_dictionary_init( &name_d, 32 );
char **ppsz_dir_list; char **ppsz_dir_list;
vlclua_dir_list( "sd", &ppsz_dir_list ); if( vlclua_dir_list( "sd", &ppsz_dir_list ) )
return VLC_ENOMEM;
vlc_dictionary_init( &name_d, 32 );
for( char **ppsz_dir = ppsz_dir_list; *ppsz_dir; ppsz_dir++ ) for( char **ppsz_dir = ppsz_dir_list; *ppsz_dir; ppsz_dir++ )
{ {
char **ppsz_filelist; char **ppsz_filelist;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment