diff options
author | Vincent Vanlaer <vincent.vanlaer@skynet.be> | 2018-05-06 20:23:10 +0200 |
---|---|---|
committer | Vincent Vanlaer <vincent.vanlaer@skynet.be> | 2018-05-06 23:41:25 +0200 |
commit | c80bf1591e5cea26bd29e1b4b4680d4ef3693833 (patch) | |
tree | b64a5554864bf6bd357222c3b3530009456ea335 /include | |
parent | 2959fcce1ac410904ebb2d1b11bbc954d0c00c26 (diff) |
Allow xwayland to start lazily
Makes the xwayland startup process two phased.
The first phase just initialises the X11 sockets.
The second phase starts the Xwayland server itself.
When starting xwayland lazily the second phase will be postponed until
a client has connected to the X11 socket.
Changes in behaviour:
The DISPLAY environment is now set immediately after the X11 sockets
are created.
When the Xwayland server is killed or crashes, the sockets will not be
recreated, but reused.
Fixes #849: Start up Xwayland lazily
Diffstat (limited to 'include')
-rw-r--r-- | include/wlr/xwayland.h | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/include/wlr/xwayland.h b/include/wlr/xwayland.h index b2c23667..a802d32d 100644 --- a/include/wlr/xwayland.h +++ b/include/wlr/xwayland.h @@ -15,10 +15,12 @@ struct wlr_xwayland { pid_t pid; int display; int x_fd[2], wl_fd[2], wm_fd[2]; + struct wl_event_source *x_fd_read_event[2]; struct wl_client *client; struct wl_display *wl_display; struct wlr_compositor *compositor; time_t server_start; + bool lazy; struct wl_event_source *sigusr1_source; struct wl_listener client_destroy; @@ -168,7 +170,7 @@ struct wlr_xwayland_resize_event { }; struct wlr_xwayland *wlr_xwayland_create(struct wl_display *wl_display, - struct wlr_compositor *compositor); + struct wlr_compositor *compositor, bool lazy); void wlr_xwayland_destroy(struct wlr_xwayland *wlr_xwayland); |