Commit 03328d73 authored by Rafaël Carré's avatar Rafaël Carré

lua: check stream_UrlNew return value

parent 9bfa71e7
...@@ -86,6 +86,7 @@ int vlclua_stream_new( lua_State *p_state ) ...@@ -86,6 +86,7 @@ int vlclua_stream_new( lua_State *p_state )
psz_url = lua_tostring( p_state, 1 ); psz_url = lua_tostring( p_state, 1 );
lua_pop( p_state, i ); lua_pop( p_state, i );
p_stream = stream_UrlNew( p_this, psz_url ); p_stream = stream_UrlNew( p_this, psz_url );
if( !p_stream ) return 0;
lua_pushlightuserdata( p_state, p_stream ); lua_pushlightuserdata( p_state, p_stream );
return 1; return 1;
} }
......
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