summaryrefslogtreecommitdiff
path: root/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'Source/Core/VideoCommon/Src/TextureCacheBase.cpp')
-rw-r--r--Source/Core/VideoCommon/Src/TextureCacheBase.cpp7
1 files changed, 5 insertions, 2 deletions
diff --git a/Source/Core/VideoCommon/Src/TextureCacheBase.cpp b/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
index 41af7ac946..c29a59e2b4 100644
--- a/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
+++ b/Source/Core/VideoCommon/Src/TextureCacheBase.cpp
@@ -470,8 +470,11 @@ TextureCache::TCacheEntryBase* TextureCache::Load(unsigned int const stage,
expandedHeight = height;
// If we thought we could reuse the texture before, make sure to pool it now!
- PoolTexture(entry);
- entry = NULL;
+ if(entry)
+ {
+ PoolTexture(entry);
+ entry = NULL;
+ }
}
using_custom_texture = true;
}