mirror of
https://gitlab.freedesktop.org/pipewire/wireplumber.git
synced 2026-05-09 10:58:05 +02:00
m-lua-scripting/api: fix access to core in session_item_new()
This commit is contained in:
parent
1bd8e31872
commit
fb5706eacc
1 changed files with 1 additions and 8 deletions
|
|
@ -691,15 +691,8 @@ impl_node_new (lua_State *L)
|
|||
static int
|
||||
session_item_new (lua_State *L)
|
||||
{
|
||||
WpSessionItem *si = NULL;
|
||||
const char *type = luaL_checkstring (L, 1);
|
||||
WpCore *core = NULL;
|
||||
|
||||
lua_pushliteral (L, "wireplumber_core");
|
||||
lua_gettable (L, LUA_REGISTRYINDEX);
|
||||
core = lua_touserdata (L, -1);
|
||||
|
||||
si = wp_session_item_make (core, type);
|
||||
WpSessionItem *si = wp_session_item_make (get_wp_core (L), type);
|
||||
wplua_pushobject (L, si);
|
||||
return 1;
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue