From a0011a9e39b260197f38a4d8d6b028dfd339172d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Sun, 16 Aug 2026 19:15:17 +0200 Subject: [PATCH] Platform: renove old workaround for a hidden GLFW Wayland window crash. This was fixed in GLFW 3.3.7, released in 2022. As with the workaround removed in the previous commit, it isn't reasonable to keep old patches for functionality that used to be broken but is long fixed upstream. IOW, if you're hitting this bug, either update GLFW or downgrade Magnum to a version before this commit. https://github.com/glfw/glfw/commit/094aa6d3c721397825cb1095c156353463ecafb5 This reverts commit c8d2c33ac60a01c17183f7d7f7d5a6cf0d81fc5c. --- src/Magnum/Platform/GlfwApplication.cpp | 10 ++-------- 1 file changed, 2 insertions(+), 8 deletions(-) diff --git a/src/Magnum/Platform/GlfwApplication.cpp b/src/Magnum/Platform/GlfwApplication.cpp index 8ce890bc6..dacbbb397 100644 --- a/src/Magnum/Platform/GlfwApplication.cpp +++ b/src/Magnum/Platform/GlfwApplication.cpp @@ -544,14 +544,8 @@ bool GlfwApplication::tryCreate(const Configuration& configuration, const GLConf /* Create window. Hide it by default so we don't have distracting window blinking in case we have to destroy it again right away. If the creation - succeeds, make the context current so we can query GL_VENDOR below. - If we are on Wayland, this is causing a segfault; a blinking window is - acceptable in this case. */ - if(std::getenv("XDG_SESSION_TYPE") != "wayland"_s) - glfwWindowHint(GLFW_VISIBLE, false); - else if(_verboseLog) - Warning{} << "Platform::GlfwApplication: Wayland detected, GL context has to be created with the window visible and may cause flicker on startup"; - CORRADE_INTERNAL_ASSERT(configuration.title().flags() & Containers::StringViewFlag::NullTerminated); + succeeds, make the context current so we can query GL_VENDOR below. */ + glfwWindowHint(GLFW_VISIBLE, false); if((_window = glfwCreateWindow(scaledWindowSize.x(), scaledWindowSize.y(), configuration.title().data(), monitor, nullptr))) glfwMakeContextCurrent(_window);