diff options
author | emersion <contact@emersion.fr> | 2018-05-19 09:34:16 +0100 |
---|---|---|
committer | emersion <contact@emersion.fr> | 2018-05-19 09:34:16 +0100 |
commit | 9e3dd6b5600ac3304d33d053714530ac066237db (patch) | |
tree | 65b1e8a0fcfef7c7d5dbadad1f4554713cf90cfe | |
parent | 75b10cd62177a40f14f8ca610b13292726bba169 (diff) |
backend/wayland: fix segfault when destroying backend before starting it
-rw-r--r-- | backend/wayland/backend.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/backend/wayland/backend.c b/backend/wayland/backend.c index dc50cf23..4e4ca077 100644 --- a/backend/wayland/backend.c +++ b/backend/wayland/backend.c @@ -87,7 +87,9 @@ static void backend_destroy(struct wlr_backend *wlr_backend) { free(backend->seat_name); - wl_event_source_remove(backend->remote_display_src); + if (backend->remote_display_src) { + wl_event_source_remove(backend->remote_display_src); + } wlr_renderer_destroy(backend->renderer); wlr_egl_finish(&backend->egl); if (backend->pointer) { |