diff options
author | Andrei Karas <akaras@inbox.ru> | 2014-07-01 21:54:42 +0300 |
---|---|---|
committer | Andrei Karas <akaras@inbox.ru> | 2014-07-01 21:54:42 +0300 |
commit | d3b57bd96a07a674432fd28cefd2f20ae5404b8b (patch) | |
tree | 3472fa69b3a1b4879f22e371eef75b5e1fbad106 | |
parent | 5c7aca79bf39182e01dfcae4b69a0ace8142e9b2 (diff) | |
download | manaplus-d3b57bd96a07a674432fd28cefd2f20ae5404b8b.tar.gz manaplus-d3b57bd96a07a674432fd28cefd2f20ae5404b8b.tar.bz2 manaplus-d3b57bd96a07a674432fd28cefd2f20ae5404b8b.tar.xz manaplus-d3b57bd96a07a674432fd28cefd2f20ae5404b8b.zip |
Dont invalidate non existing images.
It create issues atleast in Mesa.
-rw-r--r-- | src/resources/image.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/resources/image.cpp b/src/resources/image.cpp index d6f5cd27c..cdfc0ed0c 100644 --- a/src/resources/image.cpp +++ b/src/resources/image.cpp @@ -471,7 +471,7 @@ void Image::SDLTerminateAlphaCache() #ifdef USE_OPENGL void Image::decRef() { - if (getRefCount() <= 1) + if (mGLImage && getRefCount() <= 1) OpenGLImageHelper::invalidate(mGLImage); Resource::decRef(); } |