diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/resources/imagehelper.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/resources/imagehelper.cpp b/src/resources/imagehelper.cpp index c94016ca1..2eb374bd4 100644 --- a/src/resources/imagehelper.cpp +++ b/src/resources/imagehelper.cpp @@ -129,6 +129,7 @@ SDL_Surface *ImageHelper::loadPng(SDL_RWops *const rw) if (!IMG_isPNG(rw)) { logger->log("Error, image is not png"); + SDL_RWclose(rw); return nullptr; } SDL_Surface *const tmpImage = MIMG_LoadPNG_RW(rw); |