X-Git-Url: https://jasonwoof.com/gitweb/?a=blobdiff_plain;f=scrotwm.c;h=92ea40dbaf18fb7f05e4761853d04fe531b8ce9b;hb=2a94bb496cd9cd883603dbea43d087e833e71033;hp=6ae2fc03ec670e5f678544293009156f66d325da;hpb=675f2603fdefc3a7ba4d1d25df086ce3123a86a0;p=spectrwm.git diff --git a/scrotwm.c b/scrotwm.c index 6ae2fc0..92ea40d 100644 --- a/scrotwm.c +++ b/scrotwm.c @@ -1914,8 +1914,9 @@ focus_win(struct ws_win *win) else { /* use larger hammer since the window was killed somehow */ TAILQ_FOREACH(cfw, &win->ws->winlist, entry) - XSetWindowBorder(display, cfw->id, - cfw->ws->r->s->c[SWM_S_COLOR_UNFOCUS].color); + if (cfw->ws && cfw->ws->r && cfw->ws->r->s) + XSetWindowBorder(display, cfw->id, + cfw->ws->r->s->c[SWM_S_COLOR_UNFOCUS].color); } win->ws->focus = win; @@ -2379,7 +2380,7 @@ stack_config(struct swm_region *r, union arg *args) if (ws->cur_layout->l_config != NULL) ws->cur_layout->l_config(ws, args->id); - if (args->id != SWM_ARG_ID_STACKINIT); + if (args->id != SWM_ARG_ID_STACKINIT) stack(); }