summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/sxwm.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/sxwm.c b/src/sxwm.c
index cb25702..d76ffaf 100644
--- a/src/sxwm.c
+++ b/src/sxwm.c
@@ -382,18 +382,16 @@ void change_workspace(int ws)
}
/* if no scratchpad found focus regular window */
- Client *cached = NULL;
if (!focused && workspaces[current_ws]) {
for (Client *c = workspaces[current_ws]; c; c = c->next) {
/* TODO TEST */
- cached = c;
if (c->mon == current_mon) {
focused = c;
current_mon = c->mon;
break;
}
- focused = cached;
- current_mon = cached->mon;
+ focused = c;
+ current_mon = c->mon;
}
}