From 3ac83b16c828fd851201145b939392e6dc4a323e Mon Sep 17 00:00:00 2001 From: Ben Vanik Date: Mon, 7 Sep 2015 09:41:44 -0700 Subject: [PATCH] Fix double window destroy. --- src/xenia/ui/window.cc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/xenia/ui/window.cc b/src/xenia/ui/window.cc index c1f6277ed..43db896d8 100644 --- a/src/xenia/ui/window.cc +++ b/src/xenia/ui/window.cc @@ -157,6 +157,10 @@ void Window::OnClose() { } void Window::OnDestroy() { + if (!context_) { + return; + } + if (--elemental_initialization_count_ == 0) { el::Shutdown(); }