From 4e24ede18d0d171c5443d3afc31b2a0726d5837a Mon Sep 17 00:00:00 2001 From: Thierry Crozat Date: Mon, 26 Nov 2018 22:41:50 +0000 Subject: SDL: Fix crash when calling OSystem::quit() and OSystem::fatalError() --- backends/platform/sdl/sdl.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/backends/platform/sdl/sdl.cpp b/backends/platform/sdl/sdl.cpp index 63f1e97337..bf754d799b 100644 --- a/backends/platform/sdl/sdl.cpp +++ b/backends/platform/sdl/sdl.cpp @@ -381,12 +381,12 @@ void OSystem_SDL::setWindowCaption(const char *caption) { } void OSystem_SDL::quit() { - delete this; + destroy(); exit(0); } void OSystem_SDL::fatalError() { - delete this; + destroy(); exit(1); } -- cgit v1.2.3