From a4629707072a6fe31bece21c2fceec783f0df5ad Mon Sep 17 00:00:00 2001 From: vladislavbelov Date: Sat, 29 May 2021 23:24:36 +0000 Subject: [PATCH] Restores GL check for tests in TextureManager forgotten in 283f524fcf. Tested By: Langbart Differential Revision: https://code.wildfiregames.com/D4030 This was SVN commit r25595. --- source/graphics/TextureManager.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/graphics/TextureManager.cpp b/source/graphics/TextureManager.cpp index 928db87714..67233b5dbc 100644 --- a/source/graphics/TextureManager.cpp +++ b/source/graphics/TextureManager.cpp @@ -43,7 +43,11 @@ class SingleColorTexture { public: SingleColorTexture(const CColor& color, PIVFS vfs, const VfsPath& pathPlaceholder, const bool disableGL, CTextureManagerImpl* textureManager) + : m_Handle(0) { + if (disableGL) + return; + const SColor4ub color32 = color.AsSColor4ub(); // Construct 1x1 32-bit texture std::shared_ptr data(new u8[4], ArrayDeleter());