From a194043ea81bcc1aa1d431834327ffa778d561bb Mon Sep 17 00:00:00 2001 From: bruvzg <7645683+bruvzg@users.noreply.github.com> Date: Wed, 6 Jul 2022 09:56:47 +0300 Subject: Check if GL manager exist to prevent crash when using multithreaded renderer with Vulkan. --- platform/windows/display_server_windows.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'platform/windows') diff --git a/platform/windows/display_server_windows.cpp b/platform/windows/display_server_windows.cpp index 03d0d0e0bd..e66fa142a7 100644 --- a/platform/windows/display_server_windows.cpp +++ b/platform/windows/display_server_windows.cpp @@ -656,7 +656,9 @@ void DisplayServerWindows::delete_sub_window(WindowID p_window) { void DisplayServerWindows::gl_window_make_current(DisplayServer::WindowID p_window_id) { #if defined(GLES3_ENABLED) - gl_manager->window_make_current(p_window_id); + if (gl_manager) { + gl_manager->window_make_current(p_window_id); + } #endif } -- cgit v1.2.3