changeset 126:52148edddcc6

core: fix leak in texture creation
author David Demelier <markand@malikania.fr>
date Tue, 06 Oct 2020 13:52:18 +0200
parents d59efa737fcc
children 6691c9f69028
files libcore/core/texture.c
diffstat 1 files changed, 2 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libcore/core/texture.c	Tue Oct 06 12:43:29 2020 +0200
+++ b/libcore/core/texture.c	Tue Oct 06 13:52:18 2020 +0200
@@ -123,5 +123,7 @@
 	tex->w = surface->w;
 	tex->h = surface->h;
 
+	SDL_FreeSurface(surface);
+
 	return true;
 }