aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Statistics
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework/Statistics')
-rw-r--r--OpenSim/Framework/Statistics/SimExtraStatsReporter.cs8
1 files changed, 6 insertions, 2 deletions
diff --git a/OpenSim/Framework/Statistics/SimExtraStatsReporter.cs b/OpenSim/Framework/Statistics/SimExtraStatsReporter.cs
index 73f36f9..c8b8223 100644
--- a/OpenSim/Framework/Statistics/SimExtraStatsReporter.cs
+++ b/OpenSim/Framework/Statistics/SimExtraStatsReporter.cs
@@ -50,8 +50,12 @@ namespace OpenSim.Framework.Statistics
50 50
51 public void AddTexture(AssetBase image) 51 public void AddTexture(AssetBase image)
52 { 52 {
53 texturesInCache++; 53 // Tedd: I added null check to avoid exception. Don't know if texturesInCache should ++ anyway?
54 textureCacheMemoryUsage += image.Data.Length; 54 if (image.Data != null)
55 {
56 texturesInCache++;
57 textureCacheMemoryUsage += image.Data.Length;
58 }
55 } 59 }
56 60
57 /// <summary> 61 /// <summary>