diff --git a/base/vulkanexamplebase.cpp b/base/vulkanexamplebase.cpp index 622a1667..507666ee 100644 --- a/base/vulkanexamplebase.cpp +++ b/base/vulkanexamplebase.cpp @@ -842,7 +842,8 @@ VulkanExampleBase::~VulkanExampleBase() wl_keyboard_destroy(keyboard); if (pointer) wl_pointer_destroy(pointer); - wl_seat_destroy(seat); + if (seat) + wl_seat_destroy(seat); xdg_wm_base_destroy(shell); wl_compositor_destroy(compositor); wl_registry_destroy(registry); @@ -2128,12 +2129,17 @@ void VulkanExampleBase::initWaylandConnection() wl_registry_add_listener(registry, ®istry_listener, this); wl_display_dispatch(display); wl_display_roundtrip(display); - if (!compositor || !shell || !seat) + if (!compositor || !shell) { std::cout << "Could not bind Wayland protocols!\n"; fflush(stdout); exit(1); } + if (!seat) + { + std::cout << "WARNING: Input handling not available!\n"; + fflush(stdout); + } } void VulkanExampleBase::setSize(int width, int height)