From ebaef49516791d702a78c6ae88e415ae0ac95926 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Henrik=20Rydg=C3=A5rd?= Date: Fri, 30 Dec 2022 22:59:44 +0100 Subject: [PATCH] NativeShutdownGraphics: Check screenManager for nullptr. --- UI/NativeApp.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/UI/NativeApp.cpp b/UI/NativeApp.cpp index c92ec9ce44..1ba3abe397 100644 --- a/UI/NativeApp.cpp +++ b/UI/NativeApp.cpp @@ -985,7 +985,9 @@ bool CreateGlobalPipelines() { void NativeShutdownGraphics() { INFO_LOG(SYSTEM, "NativeShutdownGraphics"); - screenManager->deviceLost(); + if (screenManager) { + screenManager->deviceLost(); + } if (gpu) gpu->DeviceLost();