diff options
author | Tony Crisci <tony@dubstepdish.com> | 2017-10-06 07:04:27 -0400 |
---|---|---|
committer | Tony Crisci <tony@dubstepdish.com> | 2017-10-06 07:04:27 -0400 |
commit | 4657f10dd29e0dd5d27967b72e4dc1d95b34b6aa (patch) | |
tree | 7c9e6c441849604a4303df501e9a73f9c3eac384 /backend | |
parent | d3ebf99b0fcadff6b70e6d7e90b956330cefe8a1 (diff) | |
parent | b2d478a4189ffd96dc6158003f5cde76b70bd368 (diff) |
Merge branch 'master' into feature/xdg-popup
Diffstat (limited to 'backend')
-rw-r--r-- | backend/drm/backend.c | 2 | ||||
-rw-r--r-- | backend/drm/drm.c | 13 |
2 files changed, 14 insertions, 1 deletions
diff --git a/backend/drm/backend.c b/backend/drm/backend.c index 468fca6e..d7e2e616 100644 --- a/backend/drm/backend.c +++ b/backend/drm/backend.c @@ -34,8 +34,8 @@ static void wlr_drm_backend_destroy(struct wlr_backend *backend) { wlr_output_destroy(&conn->output); } - wlr_drm_renderer_finish(&drm->renderer); wlr_drm_resources_free(drm); + wlr_drm_renderer_finish(&drm->renderer); wlr_session_close_file(drm->session, drm->fd); wl_event_source_remove(drm->drm_event); list_free(drm->outputs); diff --git a/backend/drm/drm.c b/backend/drm/drm.c index 1a5fea9f..fc376b54 100644 --- a/backend/drm/drm.c +++ b/backend/drm/drm.c @@ -169,6 +169,19 @@ void wlr_drm_resources_free(struct wlr_drm_backend *drm) { drmModeDestroyPropertyBlob(drm->fd, crtc->mode_id); } } + for (size_t i = 0; i < drm->num_planes; ++i) { + struct wlr_drm_plane *plane = &drm->planes[i]; + if (plane->cursor_bo) { + gbm_bo_destroy(plane->cursor_bo); + } + if (plane->wlr_tex) { + wlr_texture_destroy(plane->wlr_tex); + } + if (plane->wlr_rend) { + wlr_renderer_destroy(plane->wlr_rend); + } + } + free(drm->crtcs); free(drm->planes); } |