---
 dwm.c | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

diff --git a/dwm.c b/dwm.c
index 4eba952..88d49d7 100644
--- a/dwm.c
+++ b/dwm.c
@@ -1896,9 +1896,8 @@ updategeom(void)
                        /* less monitors available nn < n */
                        for (i = nn; i < n; i++) {
                                for (m = mons; m && m->next; m = m->next);
-                               while (m->clients) {
+                               while ((c = m->clients)) {
                                        dirty = 1;
-                                       c = m->clients;
                                        m->clients = c->next;
                                        detachstack(c);
                                        c->mon = mons;
-- 
2.10.2


Reply via email to