summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx
index 03b550062..0cd24a890 100644
--- a/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx
+++ b/src/drivers/Wayland/Fl_Wayland_Screen_Driver.cxx
@@ -1557,6 +1557,5 @@ int Fl_Wayland_Screen_Driver::get_key(int k) {
struct wl_display *fl_wl_display() {
- if (!Fl_Wayland_Screen_Driver::wl_display || !Fl_Wayland_Screen_Driver::wl_registry) return NULL;
- return Fl_Wayland_Screen_Driver::wl_display;
+ return (Fl_Wayland_Screen_Driver::wl_registry ? Fl_Wayland_Screen_Driver::wl_display : NULL);
}