aboutsummaryrefslogtreecommitdiff
path: root/examples/compositor/main.c
diff options
context:
space:
mode:
authorDrew DeVault <sir@cmpwn.com>2017-08-19 08:45:44 -0400
committerGitHub <noreply@github.com>2017-08-19 08:45:44 -0400
commitb876bea288bc4827a9de157eed481b823c081a4b (patch)
tree94fb650815691f98ab633c7731496f14ac751dc2 /examples/compositor/main.c
parent3674085faede2960581461cf8f40c33ffce85e7c (diff)
parent84c0c87a5ddca24cb039f33eea38252681bb4636 (diff)
Merge pull request #114 from martinetd/cleanups
Cleanups
Diffstat (limited to 'examples/compositor/main.c')
-rw-r--r--examples/compositor/main.c12
1 files changed, 8 insertions, 4 deletions
diff --git a/examples/compositor/main.c b/examples/compositor/main.c
index 751a3f23..4c6e213d 100644
--- a/examples/compositor/main.c
+++ b/examples/compositor/main.c
@@ -147,7 +147,7 @@ int main() {
};
compositor_init(&compositor);
- state.renderer = wlr_gles2_renderer_init(compositor.backend);
+ state.renderer = wlr_gles2_renderer_create(compositor.backend);
if (!state.renderer) {
wlr_log(L_ERROR, "Could not start compositor, OOM");
exit(EXIT_FAILURE);
@@ -178,9 +178,13 @@ int main() {
break;
}
- compositor_run(&compositor);
+ wl_display_run(compositor.display);
- wlr_wl_shell_destroy(state.wl_shell);
- wlr_xdg_shell_v6_destroy(state.xdg_shell);
close(state.keymap_fd);
+ wlr_seat_destroy(state.wl_seat);
+ wlr_data_device_manager_destroy(state.data_device_manager);
+ wlr_xdg_shell_v6_destroy(state.xdg_shell);
+ wlr_wl_shell_destroy(state.wl_shell);
+ wlr_renderer_destroy(state.renderer);
+ compositor_fini(&compositor);
}