[vlc-commits] lua: fix vlclua_release_vlc_object prototype
Steve Lhomme
git at videolan.org
Mon Mar 2 14:19:20 CET 2020
vlc | branch: master | Steve Lhomme <robux4 at ycbcr.xyz> | Mon Mar 2 12:00:45 2020 +0100| [49baa7dba6842a7547f9f650e18e1e9acc9f86fd] | committer: Steve Lhomme
lua: fix vlclua_release_vlc_object prototype
The pushed C function must return how many items it pushed in the Lua stack.
> http://git.videolan.org/gitweb.cgi/vlc.git/?a=commit;h=49baa7dba6842a7547f9f650e18e1e9acc9f86fd
---
modules/lua/libs/objects.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/modules/lua/libs/objects.c b/modules/lua/libs/objects.c
index 420eaea8ef..1e40621e9e 100644
--- a/modules/lua/libs/objects.c
+++ b/modules/lua/libs/objects.c
@@ -49,13 +49,14 @@ typedef struct vlclua_object {
int (*release)(vlc_object_t *);
} vlclua_object_t;
-static void vlclua_release_vlc_object(lua_State *L)
+static int vlclua_release_vlc_object(lua_State *L)
{
vlclua_object_t *p_luaobj = luaL_checkudata(L, 1, "vlc_object");
lua_pop(L, 1);
if (p_luaobj->release)
p_luaobj->release(p_luaobj->object);
+ return 0;
}
static int vlclua_push_vlc_object(lua_State *L, vlc_object_t *p_obj,
More information about the vlc-commits
mailing list