From dac07340b4cdcb5f348ee220d8a7a6579b9557a2 Mon Sep 17 00:00:00 2001 From: Alexander Batalov Date: Tue, 12 Jul 2022 09:24:49 +0300 Subject: [PATCH] Fix error handling --- src/core.cc | 1 + 1 file changed, 1 insertion(+) diff --git a/src/core.cc b/src/core.cc index 00db56f..11935b6 100644 --- a/src/core.cc +++ b/src/core.cc @@ -2073,6 +2073,7 @@ int _GNW95_init_window(int width, int height, bool fullscreen) err: if (gSdlTexture != NULL) { + SDL_DestroyTexture(gSdlTexture); gSdlTexture = NULL; }