]> git.sesse.net Git - vlc/blobdiff - modules/misc/lua/libs/input.c
Lua: release input thread
[vlc] / modules / misc / lua / libs / input.c
index 20d7c125ea382bb495adc9c7eea2cf4fb9581232..fee0146eebba3e53da22b9bbb502072978aca442 100644 (file)
@@ -87,6 +87,8 @@ static int vlclua_is_playing( lua_State *L )
 {
     input_thread_t * p_input = vlclua_get_input_internal( L );
     lua_pushboolean( L, !!p_input );
+    if( p_input )
+        vlc_object_release( p_input );
     return 1;
 }
 
@@ -130,6 +132,8 @@ static int vlclua_input_stats( lua_State *L )
 #undef STATS_INT
 #undef STATS_FLOAT
     }
+    if( p_input )
+        vlc_object_release( p_input );
     return 1;
 }