aboutsummaryrefslogtreecommitdiff
path: root/wayland.c
diff options
context:
space:
mode:
authorDaniel Eklöf <daniel@ekloef.se>2020-03-09 17:49:44 +0000
committerDaniel Eklöf <daniel@ekloef.se>2020-03-09 17:49:44 +0000
commitfc7b3b2d85cc3cff87c367cb9022a3d049b9dcec (patch)
tree0b968b01b339b6af3806fe11aab6b2d88f73fd22 /wayland.c
parentfootrc: add default key bindings (diff)
parentserver/client: add XDG_SESSION_ID to the default socket path (diff)
Merge branch 'master' into bindings
Diffstat (limited to 'wayland.c')
-rw-r--r--wayland.c17
1 files changed, 9 insertions, 8 deletions
diff --git a/wayland.c b/wayland.c
index 69407964..dae16dc3 100644
--- a/wayland.c
+++ b/wayland.c
@@ -727,6 +727,11 @@ wayl_init(const struct config *conf, struct fdm *fdm)
wayl->fdm = fdm;
wayl->kbd.repeat.fd = -1;
+ if (!fdm_hook_add(fdm, &fdm_hook, wayl, FDM_HOOK_PRIORITY_LOW)) {
+ LOG_ERR("failed to add FDM hook");
+ goto out;
+ }
+
wayl->display = wl_display_connect(NULL);
if (wayl->display == NULL) {
LOG_ERR("failed to connect to wayland; no compositor running?");
@@ -775,9 +780,10 @@ wayl_init(const struct config *conf, struct fdm *fdm)
if (wayl->primary_selection_device_manager == NULL)
LOG_WARN("no primary selection available");
- if (conf->presentation_timings && wayl->presentation == NULL)
- LOG_WARN("presentation time interface not implemented by compositor; "
- "timings will not be available");
+ if (conf->presentation_timings && wayl->presentation == NULL) {
+ LOG_ERR("presentation time interface not implemented by compositor");
+ goto out;
+ }
tll_foreach(wayl->monitors, it) {
LOG_INFO(
@@ -851,11 +857,6 @@ wayl_init(const struct config *conf, struct fdm *fdm)
goto out;
}
- if (!fdm_hook_add(fdm, &fdm_hook, wayl, FDM_HOOK_PRIORITY_LOW)) {
- LOG_ERR("failed to add FDM hook");
- goto out;
- }
-
return wayl;
out: