aboutsummaryrefslogtreecommitdiff
path: root/backend/drm/backend.c
diff options
context:
space:
mode:
authorAlexander Orzechowski <alex@ozal.ski>2023-11-17 14:34:32 -0500
committerAlexander Orzechowski <alex@ozal.ski>2023-11-17 14:34:32 -0500
commitb06d58fa8b6bb5d9a154f795ec595477e13998bc (patch)
treed363d35ddf72388b8ce5171f76162caee11958e6 /backend/drm/backend.c
parent3aed24b8d4572eb4cd2488113f1c1a23ceb290d8 (diff)
backend/drm: Destroy page flips on backend destroy
When we destroy the backend, page flips will no longer be invoked meaning those won't clean up the page flips for us.
Diffstat (limited to 'backend/drm/backend.c')
-rw-r--r--backend/drm/backend.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/backend/drm/backend.c b/backend/drm/backend.c
index 5ff2b90c..40597dae 100644
--- a/backend/drm/backend.c
+++ b/backend/drm/backend.c
@@ -39,6 +39,11 @@ static void backend_destroy(struct wlr_backend *backend) {
destroy_drm_connector(conn);
}
+ struct wlr_drm_page_flip *page_flip, *page_flip_tmp;
+ wl_list_for_each_safe(page_flip, page_flip_tmp, &drm->page_flips, link) {
+ drm_page_flip_destroy(page_flip);
+ }
+
wlr_backend_finish(backend);
wl_list_remove(&drm->display_destroy.link);