aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/lltexturecache.cpp
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--linden/indra/newview/lltexturecache.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/linden/indra/newview/lltexturecache.cpp b/linden/indra/newview/lltexturecache.cpp
index 56f3719..a1a9a39 100644
--- a/linden/indra/newview/lltexturecache.cpp
+++ b/linden/indra/newview/lltexturecache.cpp
@@ -1382,7 +1382,15 @@ void LLTextureCache::purgeTextures(bool validate)
1382 { 1382 {
1383 purge_count++; 1383 purge_count++;
1384 LL_DEBUGS("TextureCache") << "PURGING: " << filename << LL_ENDL; 1384 LL_DEBUGS("TextureCache") << "PURGING: " << filename << LL_ENDL;
1385 LLAPRFile::remove(filename); 1385 if (entries[idx].mBodySize > 0)
1386 {
1387 LLAPRFile::remove(filename);
1388 }
1389 else if (LLAPRFile::isExist(filename)) // Sanity check. Shouldn't exist.
1390 {
1391 LL_WARNS("TextureCache") << "Entry has zero body size but existing " << filename << ". Deleting file too..." << LL_ENDL;
1392 LLAPRFile::remove(filename);
1393 }
1386 cache_size -= entries[idx].mBodySize; 1394 cache_size -= entries[idx].mBodySize;
1387 mTexturesSizeTotal -= entries[idx].mBodySize; 1395 mTexturesSizeTotal -= entries[idx].mBodySize;
1388 entries[idx].mBodySize = 0; 1396 entries[idx].mBodySize = 0;