modules/i3: Add unused attribute to focused

This variable is only used in assert() which expands to nothing in
release builds. Adding the unused attribute prevents the compiler from
throwing an error (-Wunused-but-set-variable) when building.
This commit is contained in:
Nicholas Sudsgaard 2025-03-04 14:46:08 +09:00
parent d96ff374b1
commit efaa7ec3d0

View file

@ -594,7 +594,7 @@ handle_window_event(int sock, int type, const struct json_object *json, void *_m
mtx_lock(&mod->lock); mtx_lock(&mod->lock);
struct workspace *ws = NULL; struct workspace *ws = NULL;
size_t focused = 0; __attribute__((unused)) size_t focused = 0;
tll_foreach(m->workspaces, it) tll_foreach(m->workspaces, it)
{ {
if (it->item.focused) { if (it->item.focused) {