diff options
author | Simon Ser <contact@emersion.fr> | 2023-10-10 16:56:11 +0200 |
---|---|---|
committer | Simon Ser <contact@emersion.fr> | 2023-10-10 17:05:04 +0200 |
commit | bdcf997a8985831fcd88c018e92acab6a9a5ed5c (patch) | |
tree | c9d171c47f901d2a41ab466d66d62bc44dd4aa14 | |
parent | 45ba35719e874f7e8651e088c0582fe50301e731 (diff) |
xwayland/server: add ready flag
Allows one to check whether the server is currently ready.
-rw-r--r-- | include/wlr/xwayland/server.h | 1 | ||||
-rw-r--r-- | xwayland/server.c | 1 |
2 files changed, 2 insertions, 0 deletions
diff --git a/include/wlr/xwayland/server.h b/include/wlr/xwayland/server.h index 7eb3bc2a..fa16a3b0 100644 --- a/include/wlr/xwayland/server.h +++ b/include/wlr/xwayland/server.h @@ -27,6 +27,7 @@ struct wlr_xwayland_server { struct wl_client *client; struct wl_event_source *pipe_source; int wm_fd[2], wl_fd[2]; + bool ready; time_t server_start; diff --git a/xwayland/server.c b/xwayland/server.c index d53f8ada..fde3d610 100644 --- a/xwayland/server.c +++ b/xwayland/server.c @@ -275,6 +275,7 @@ static int xserver_handle_ready(int fd, uint32_t mask, void *data) { close(fd); wl_event_source_remove(server->pipe_source); server->pipe_source = NULL; + server->ready = true; struct wlr_xwayland_server_ready_event event = { .server = server, |