]> git.sesse.net Git - vlc/commitdiff
Lua: release input thread
authorJean-Philippe André <jpeg@endymion.via.ecp.fr>
Wed, 11 Nov 2009 18:05:49 +0000 (19:05 +0100)
committerJean-Philippe André <jpeg@endymion.via.ecp.fr>
Wed, 11 Nov 2009 18:05:49 +0000 (19:05 +0100)
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;
 }