From 4c3e1cebf88ea959cd9c2a6999efe64bd15bd660 Mon Sep 17 00:00:00 2001 From: Julien Danjou Date: Wed, 29 Jul 2009 09:39:06 +0200 Subject: [PATCH] widget: fix element poping Signed-off-by: Julien Danjou --- widget.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/widget.c b/widget.c index abd7f669..c2666f70 100644 --- a/widget.c +++ b/widget.c @@ -184,6 +184,9 @@ widget_geometries(wibox_t *wibox) } else { + /* Remove the "nil function" */ + lua_pop(globalconf.L, 1); + /* If no layout function has been specified, we just push a table with * geometries onto the stack. These geometries are nothing fancy, they * have x = y = 0 and their height and width set to the widgets demands @@ -201,7 +204,6 @@ widget_geometries(wibox_t *wibox) /* remove wibox */ lua_remove(globalconf.L, -2); luaA_table2widgets(globalconf.L, widgets); - lua_pop(globalconf.L, 2); lua_newtable(globalconf.L); for(int i = 0; i < widgets->len; i++)