diff options
author | Simon Ser <contact@emersion.fr> | 2022-06-05 09:44:55 +0200 |
---|---|---|
committer | Benjamin Tissoires <benjamin.tissoires@gmail.com> | 2022-06-05 10:36:11 +0000 |
commit | 99f63b03e7970093cf4b8028b21b26b656e14e6f (patch) | |
tree | 5a0cee70e1ebc22f1bff189509cd9671372ee1cf /render/allocator/allocator.c | |
parent | 808e660291309ad36581356cb7a3931657d228af (diff) |
Remove remaining wl_signal_emit calls
Replace them with wlr_signal_emit_safe, which correctly handles
cases where a listener removes another listener.
Reported-by: Isaac Freund <ifreund@ifreund.xyz>
Diffstat (limited to 'render/allocator/allocator.c')
-rw-r--r-- | render/allocator/allocator.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/render/allocator/allocator.c b/render/allocator/allocator.c index 6b96e023..00dadd29 100644 --- a/render/allocator/allocator.c +++ b/render/allocator/allocator.c @@ -14,6 +14,7 @@ #include "render/allocator/drm_dumb.h" #include "render/allocator/shm.h" #include "render/wlr_renderer.h" +#include "util/signal.h" #if WLR_HAS_GBM_ALLOCATOR #include "render/allocator/gbm.h" @@ -158,7 +159,7 @@ void wlr_allocator_destroy(struct wlr_allocator *alloc) { if (alloc == NULL) { return; } - wl_signal_emit(&alloc->events.destroy, NULL); + wlr_signal_emit_safe(&alloc->events.destroy, NULL); alloc->impl->destroy(alloc); } |