--- a/finch/libgnt/gntwm.c Thu Apr 03 18:23:35 2014 +0200 +++ b/finch/libgnt/gntwm.c Thu Apr 03 18:45:27 2014 +0200 @@ -2251,8 +2251,14 @@ void gnt_wm_raise_window(GntWM *wm, GntWidget *widget) { GntWS *ws = gnt_wm_widget_find_workspace(wm, widget); + + g_return_if_fail(wm != NULL); + if (wm->cws != ws) gnt_wm_switch_workspace(wm, g_list_index(wm->workspaces, ws)); + + g_return_if_fail(wm->cws != NULL); + if (widget != wm->cws->ordered->data) { GntWidget *wid = wm->cws->ordered->data; wm->cws->ordered = g_list_bring_to_front(wm->cws->ordered, widget);