From 5a18ea31cf9d9a97fc1a65f8623b633c244221c2 Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Mon, 30 Jan 2017 13:59:05 +0000 Subject: Make negative asset caching actually work Also fixes some merge artefacts in HGAssetBroker where cached assets were requested but not actually used and completely squelch a materials debug message because there is nothing the user can do to fix it anyway. --- OpenSim/Framework/WearableCacheItem.cs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'OpenSim/Framework/WearableCacheItem.cs') diff --git a/OpenSim/Framework/WearableCacheItem.cs b/OpenSim/Framework/WearableCacheItem.cs index ccaf69e..f181c39 100644 --- a/OpenSim/Framework/WearableCacheItem.cs +++ b/OpenSim/Framework/WearableCacheItem.cs @@ -113,7 +113,8 @@ namespace OpenSim.Framework { if (dataCache.Check(item.TextureID.ToString())) { - AssetBase assetItem = dataCache.Get(item.TextureID.ToString()); + bool negative; + AssetBase assetItem = dataCache.Get(item.TextureID.ToString(), out negative); if (assetItem != null) { itemmap.Add("assetdata", OSD.FromBinary(assetItem.Data)); -- cgit v1.1 From a5151bb337cfee14dff6045d7f8e293201ae94ac Mon Sep 17 00:00:00 2001 From: Melanie Thielker Date: Wed, 1 Feb 2017 16:31:01 +0000 Subject: Refactor asset handling as per Ubit's suggestion --- OpenSim/Framework/WearableCacheItem.cs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'OpenSim/Framework/WearableCacheItem.cs') diff --git a/OpenSim/Framework/WearableCacheItem.cs b/OpenSim/Framework/WearableCacheItem.cs index f181c39..427e149 100644 --- a/OpenSim/Framework/WearableCacheItem.cs +++ b/OpenSim/Framework/WearableCacheItem.cs @@ -113,8 +113,8 @@ namespace OpenSim.Framework { if (dataCache.Check(item.TextureID.ToString())) { - bool negative; - AssetBase assetItem = dataCache.Get(item.TextureID.ToString(), out negative); + AssetBase assetItem; + dataCache.Get(item.TextureID.ToString(), out assetItem); if (assetItem != null) { itemmap.Add("assetdata", OSD.FromBinary(assetItem.Data)); -- cgit v1.1