mirror of
https://github.com/artizirk/wdisplays.git
synced 2026-10-03 12:55:42 +03:00
Clear head output when the output is destroyed
This commit is contained in:
@@ -310,6 +310,12 @@ static void wd_output_destroy(struct wd_output *output) {
|
||||
if (output->state->layer_shell != NULL) {
|
||||
wd_destroy_overlay(output);
|
||||
}
|
||||
struct wd_head *head;
|
||||
wl_list_for_each(head, &output->state->heads, link) {
|
||||
if (head->output == output) {
|
||||
head->output = NULL;
|
||||
}
|
||||
}
|
||||
zxdg_output_v1_destroy(output->xdg_output);
|
||||
free(output->name);
|
||||
free(output);
|
||||
|
||||
Reference in New Issue
Block a user