diff --git a/source/common/platform/win32/i_main.cpp b/source/common/platform/win32/i_main.cpp index 6e1b2ea33..01d799998 100644 --- a/source/common/platform/win32/i_main.cpp +++ b/source/common/platform/win32/i_main.cpp @@ -1242,7 +1242,7 @@ int WINAPI wWinMain (HINSTANCE hInstance, HINSTANCE nothing, LPWSTR cmdline, int _CrtSetDbgFlag (_CrtSetDbgFlag(0) | _CRTDBG_LEAK_CHECK_DF); // Use this to break at a specific allocation number. - //_crtBreakAlloc = 227524; + //_crtBreakAlloc = 291757; #endif int ret = DoMain (hInstance); diff --git a/source/common/textures/imagetexture.cpp b/source/common/textures/imagetexture.cpp index d222733a7..5ec15c7b5 100644 --- a/source/common/textures/imagetexture.cpp +++ b/source/common/textures/imagetexture.cpp @@ -57,6 +57,11 @@ FImageTexture::FImageTexture(FImageSource *img) noexcept } } +FImageTexture::~FImageTexture() +{ + delete mImage; +} + void FImageTexture::SetFromImage() { auto img = mImage; diff --git a/source/common/textures/textures.h b/source/common/textures/textures.h index f8fd763cf..c5a85fd6b 100644 --- a/source/common/textures/textures.h +++ b/source/common/textures/textures.h @@ -357,6 +357,7 @@ protected: void SetFromImage(); public: FImageTexture(FImageSource* image) noexcept; + ~FImageTexture(); TArray Get8BitPixels(bool alphatex) override; void SetImage(FImageSource* img)