Don't call SP::SPTextureManager::get() if not GLSL to avoid leaking

This commit is contained in:
Benau 2018-09-30 13:00:24 +08:00
parent 05e1d629ee
commit cb9a17563e

View File

@ -23,6 +23,7 @@
#include <sstream> #include <sstream>
#include "config/user_config.hpp" #include "config/user_config.hpp"
#include "graphics/central_settings.hpp"
#include "graphics/material.hpp" #include "graphics/material.hpp"
#include "graphics/particle_kind_manager.hpp" #include "graphics/particle_kind_manager.hpp"
#include "graphics/sp/sp_texture_manager.hpp" #include "graphics/sp/sp_texture_manager.hpp"
@ -57,6 +58,7 @@ MaterialManager::MaterialManager()
MaterialManager::~MaterialManager() MaterialManager::~MaterialManager()
{ {
#ifndef SERVER_ONLY #ifndef SERVER_ONLY
if (CVS->isGLSL())
SP::SPTextureManager::get()->stopThreads(); SP::SPTextureManager::get()->stopThreads();
#endif #endif