diff options
| author | Alyssa Ross <hi@alyssa.is> | 2023-09-21 06:59:48 +0000 |
|---|---|---|
| committer | Alyssa Ross <hi@alyssa.is> | 2023-09-21 06:59:48 +0000 |
| commit | 9257273d84de2ef75ab505c9f954e0af6a2af78d (patch) | |
| tree | 3e7a7a443a012a243aaf629541a46b11d8aebe3b | |
| parent | doc: keybings default none (diff) | |
wayland: check activation supported before activating
It's possible for token to be set when the compositor doesn't support
activation, and this caused a segfault. For example, this can happen
when overriding WAYLAND_DISPLAY to point to a compositor that doesn't
support activation, in a terminal running under one that does, and so
has set XDG_ACTIVATION_TOKEN.
| -rw-r--r-- | wayland.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -1701,7 +1701,7 @@ wayl_win_init(struct terminal *term, const char *token) wl_surface_commit(win->surface.surf); /* Complete XDG startup notification */ - if (token) + if (token && wayl->xdg_activation) xdg_activation_v1_activate(wayl->xdg_activation, token, win->surface.surf); if (!wayl_win_subsurface_new(win, &win->overlay, false)) { |
