avoid usage of goto
Based on this suggestion: https://github.com/guyuming76/dwl/commit/bc72af6e2430cfb8db2f5fa1b9800c86f445b6d6#commitcomment-85592855
This commit is contained in:
@@ -2388,14 +2388,12 @@ unmapnotify(struct wl_listener *listener, void *data)
|
|||||||
if (c->mon)
|
if (c->mon)
|
||||||
c->mon->un_map = 1;
|
c->mon->un_map = 1;
|
||||||
|
|
||||||
if (client_is_unmanaged(c))
|
if (!client_is_unmanaged(c)) {
|
||||||
goto end;
|
|
||||||
|
|
||||||
wl_list_remove(&c->link);
|
wl_list_remove(&c->link);
|
||||||
setmon(c, NULL, 0);
|
setmon(c, NULL, 0);
|
||||||
wl_list_remove(&c->flink);
|
wl_list_remove(&c->flink);
|
||||||
|
}
|
||||||
|
|
||||||
end:
|
|
||||||
wl_list_remove(&c->commit.link);
|
wl_list_remove(&c->commit.link);
|
||||||
wlr_scene_node_destroy(c->scene);
|
wlr_scene_node_destroy(c->scene);
|
||||||
printstatus();
|
printstatus();
|
||||||
|
|||||||
Reference in New Issue
Block a user