From 1029577a51f43d96056172e4653f92d94fe8f75e Mon Sep 17 00:00:00 2001 From: Christian Rauch Date: Thu, 22 Jul 2021 21:41:28 +0100 Subject: GHOST/wayland: explicitly delete 'GHOST_SystemWayland' when fallback to X11 --- intern/ghost/intern/GHOST_ISystem.cpp | 2 ++ 1 file changed, 2 insertions(+) (limited to 'intern/ghost') diff --git a/intern/ghost/intern/GHOST_ISystem.cpp b/intern/ghost/intern/GHOST_ISystem.cpp index 7c12bfe0306..d9fecda22a4 100644 --- a/intern/ghost/intern/GHOST_ISystem.cpp +++ b/intern/ghost/intern/GHOST_ISystem.cpp @@ -60,6 +60,8 @@ GHOST_TSuccess GHOST_ISystem::createSystem() } catch (const std::runtime_error &) { /* fallback to X11. */ + delete m_system; + m_system = nullptr; } if (!m_system) { m_system = new GHOST_SystemX11(); -- cgit v1.2.3