From b48572cecc521258d59b2f2ca944bcad8259b535 Mon Sep 17 00:00:00 2001 From: anthark Date: Sun, 8 Dec 2024 17:15:33 +0300 Subject: [PATCH] Fix crash on start-up of MinimalAppSample --- .../src/platform/windows/windows_window_manager_impl.cpp | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/engine/core/modules/platform_app/src/platform/windows/windows_window_manager_impl.cpp b/engine/core/modules/platform_app/src/platform/windows/windows_window_manager_impl.cpp index b536b4e6..edf5f2a9 100644 --- a/engine/core/modules/platform_app/src/platform/windows/windows_window_manager_impl.cpp +++ b/engine/core/modules/platform_app/src/platform/windows/windows_window_manager_impl.cpp @@ -289,8 +289,11 @@ namespace nau int height = HIWORD(lParam); auto* const coreGraphics = getServiceProvider().find(); - auto task = coreGraphics->requestViewportResize(width, height, hWnd); - task.detach(); + if (coreGraphics) + { + auto task = coreGraphics->requestViewportResize(width, height, hWnd); + task.detach(); + } } else if (message == WM_DESTROY) {