Don't abandon a null texture
This commit is contained in:
committed by
Thiago Marcos P. Santos
parent
0cce08b67b
commit
3ef8d8728e
@@ -21,8 +21,10 @@ LineAtlas::LineAtlas(uint16_t w, uint16_t h)
|
||||
LineAtlas::~LineAtlas() {
|
||||
std::lock_guard<std::recursive_mutex> lock(mtx);
|
||||
|
||||
Environment::Get().abandonTexture(texture);
|
||||
texture = 0;
|
||||
if (texture) {
|
||||
Environment::Get().abandonTexture(texture);
|
||||
texture = 0;
|
||||
}
|
||||
}
|
||||
|
||||
LinePatternPos LineAtlas::getDashPosition(const std::vector<float> &dasharray, bool round) {
|
||||
|
||||
Reference in New Issue
Block a user