diff options
author | Ilya Trukhanov <lahvuun@protonmail.com> | 2019-01-18 21:33:23 +0200 |
---|---|---|
committer | Ilya Trukhanov <lahvuun@protonmail.com> | 2019-01-18 22:53:32 +0200 |
commit | 268cc450b65a2f62e71da80d41ddf64b63760d2d (patch) | |
tree | 5eaac4810ad482ee084f6720cf177220451aa1e3 | |
parent | 3e21d0bd4839dc8180c56d426f5b3311fdd2715f (diff) |
Fix segfault in get_relative_pointer
Occurs on subsequent calls to
relative_pointer_manager_v1_handle_get_relative_pointer()
Steps to reproduce:
- run rootston
- run examples/relative-pointer
- switch to relative pointer more than once
Note: if done fast enough it may take more than two switches to crash.
-rw-r--r-- | types/wlr_relative_pointer_v1.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/types/wlr_relative_pointer_v1.c b/types/wlr_relative_pointer_v1.c index 99dea6bf..c4690087 100644 --- a/types/wlr_relative_pointer_v1.c +++ b/types/wlr_relative_pointer_v1.c @@ -42,6 +42,7 @@ static void relative_pointer_destroy(struct wlr_relative_pointer_v1 *relative_po wl_list_remove(&relative_pointer->link); wl_list_remove(&relative_pointer->seat_destroy.link); + wl_list_remove(&relative_pointer->pointer_destroy.link); wl_resource_set_user_data(relative_pointer->resource, NULL); free(relative_pointer); |