Destroy outputs before heads on shutdown

This commit is contained in:
Mars-Wave
2026-04-12 17:37:16 +02:00
parent 4ef6948efc
commit d657f9236e
+4 -4
View File
@@ -684,14 +684,14 @@ void wd_capture_wait(struct wd_state *state, struct wl_display *display) {
}
void wd_state_destroy(struct wd_state *state) {
struct wd_head *head, *head_tmp;
wl_list_for_each_safe(head, head_tmp, &state->heads, link) {
wd_head_destroy(head);
}
struct wd_output *output, *output_tmp;
wl_list_for_each_safe(output, output_tmp, &state->outputs, link) {
wd_output_destroy(output);
}
struct wd_head *head, *head_tmp;
wl_list_for_each_safe(head, head_tmp, &state->heads, link) {
wd_head_destroy(head);
}
if (state->layer_shell != NULL) {
zwlr_layer_shell_v1_destroy(state->layer_shell);
}