[vlc-commits] lua/input: playlist cannot be nul

Rémi Denis-Courmont git at videolan.org
Wed Mar 6 21:57:42 CET 2019


vlc | branch: master | Rémi Denis-Courmont <remi at remlab.net> | Wed Mar  6 22:32:11 2019 +0200| [d1ffbbf01ec049fec77e27fa4e4ab029cfc332c3] | committer: Rémi Denis-Courmont

lua/input: playlist cannot be nul

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

 modules/lua/libs/input.c | 9 +--------
 1 file changed, 1 insertion(+), 8 deletions(-)

diff --git a/modules/lua/libs/input.c b/modules/lua/libs/input.c
index 0a0fed10b4..ec4679bb38 100644
--- a/modules/lua/libs/input.c
+++ b/modules/lua/libs/input.c
@@ -59,14 +59,7 @@ input_thread_t * vlclua_get_input_internal( lua_State *L )
     }
 
     playlist_t *p_playlist = vlclua_get_playlist_internal( L );
-    if( p_playlist != NULL )
-    {
-        input_thread_t *p_input = playlist_CurrentInput( p_playlist );
-        if( p_input )
-            return p_input;
-    }
-
-    return NULL;
+    return playlist_CurrentInput( p_playlist );
 }
 
 static int vlclua_input_item_info( lua_State *L )



More information about the vlc-commits mailing list