diff options
author | Drew DeVault <sir@cmpwn.com> | 2018-02-13 08:30:54 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-02-13 08:30:54 -0500 |
commit | 71cba94e73022d8cef8651055204a4706377ae11 (patch) | |
tree | 8ea1a2b6a0414fd7904824ffac330cd4e1e96ca2 /xwayland/xwayland.c | |
parent | 3497e53516d96ad67b26115e2e06218f68e1114d (diff) | |
parent | c2e147401048aa53aebd52f1851b1da8c91043a3 (diff) |
Merge pull request #627 from emersion/wlr-signal-emit-safe
Remove wlr_backend.events.{output_remove,device_remove}
Diffstat (limited to 'xwayland/xwayland.c')
-rw-r--r-- | xwayland/xwayland.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/xwayland/xwayland.c b/xwayland/xwayland.c index 6c700cc5..1d935180 100644 --- a/xwayland/xwayland.c +++ b/xwayland/xwayland.c @@ -4,22 +4,23 @@ // for SOCK_CLOEXEC #define __BSD_VISIBLE 1 #endif -#include <stdlib.h> -#include <stdio.h> -#include <unistd.h> +#include <errno.h> #include <fcntl.h> #include <signal.h> +#include <stdio.h> +#include <stdlib.h> +#include <stdlib.h> #include <sys/socket.h> #include <sys/types.h> #include <sys/wait.h> #include <time.h> -#include <stdlib.h> -#include <errno.h> +#include <unistd.h> #include <wayland-server.h> -#include "wlr/util/log.h" -#include "wlr/xwayland.h" +#include <wlr/util/log.h> +#include <wlr/xwayland.h> +#include <wlr/xwm.h> #include "sockets.h" -#include "wlr/xwm.h" +#include "util/signal.h" #ifdef __FreeBSD__ static inline int clearenv(void) { @@ -237,7 +238,7 @@ static int xserver_handle_ready(int signal_number, void *data) { snprintf(display_name, sizeof(display_name), ":%d", wlr_xwayland->display); setenv("DISPLAY", display_name, true); - wl_signal_emit(&wlr_xwayland->events.ready, wlr_xwayland); + wlr_signal_emit_safe(&wlr_xwayland->events.ready, wlr_xwayland); /* ready is a one-shot signal, fire and forget */ wl_signal_init(&wlr_xwayland->events.ready); |