diff --git a/client.c b/client.c index 177f6ac0..e61ccaf6 100644 --- a/client.c +++ b/client.c @@ -53,6 +53,7 @@ luaA_client_gc(lua_State *L) { client_t *c = luaL_checkudata(L, 1, "client"); button_array_wipe(&c->buttons); + image_unref(L, c->icon); p_delete(&c->class); p_delete(&c->instance); p_delete(&c->icon_name); diff --git a/wibox.c b/wibox.c index 22e5ea6d..97ac3e00 100644 --- a/wibox.c +++ b/wibox.c @@ -40,6 +40,7 @@ luaA_wibox_gc(lua_State *L) wibox_t *wibox = luaL_checkudata(L, 1, "wibox"); simplewindow_wipe(&wibox->sw); button_array_wipe(&wibox->buttons); + image_unref(L, wibox->bg_image); luaL_unref(L, LUA_REGISTRYINDEX, wibox->widgets_table); luaL_unref(L, LUA_REGISTRYINDEX, wibox->mouse_enter); luaL_unref(L, LUA_REGISTRYINDEX, wibox->mouse_leave);