summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2022-08-06 10:27:17 +0200
committerManoloFLTK <41016272+ManoloFLTK@users.noreply.github.com>2022-08-06 10:27:17 +0200
commit33ea30432f528a80d4e787a6f23a4096ead69154 (patch)
tree49ac98fb1be6606d2419ee13ba4dc3b00d2e6646
parente73e13120e2018297d7b5abb4bae552384b3e6dd (diff)
Check for error while communicating with Wayland - cont'd.
-rw-r--r--src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx
index 44f0640ae..6178b4c84 100644
--- a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx
+++ b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx
@@ -40,6 +40,7 @@
#include <assert.h>
#include <sys/mman.h>
#include <poll.h>
+#include <errno.h>
extern "C" {
bool libdecor_get_cursor_settings(char **theme, int *size);
}
@@ -1068,8 +1069,8 @@ static void fd_callback(int fd, struct wl_display *display) {
struct pollfd fds = (struct pollfd) { fd, POLLIN, 0 };
do {
if (wl_display_dispatch(display) == -1) {
- Fl::fatal("Fatal error while communicating with the Wayland server: errno=%d\n",
- wl_display_get_error(display));
+ Fl::fatal("Fatal error while communicating with the Wayland server: %s",
+ strerror(errno));
}
}
while (poll(&fds, 1, 0) > 0);