aboutsummaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorMelanie Thielker2009-05-14 03:07:00 +0000
committerMelanie Thielker2009-05-14 03:07:00 +0000
commit50b305b006846121b2412637e70ce112df2fb8cb (patch)
tree82f312619bcfc1a331a1f5afbb968fa030204476
parent* Bug fix: Variable m_regionSettings can be null, using RegionSettings instea... (diff)
downloadopensim-SC_OLD-50b305b006846121b2412637e70ce112df2fb8cb.zip
opensim-SC_OLD-50b305b006846121b2412637e70ce112df2fb8cb.tar.gz
opensim-SC_OLD-50b305b006846121b2412637e70ce112df2fb8cb.tar.bz2
opensim-SC_OLD-50b305b006846121b2412637e70ce112df2fb8cb.tar.xz
Honor the temp and local asset flags
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs2
-rw-r--r--OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs10
2 files changed, 12 insertions, 0 deletions
diff --git a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs
index bd4638a..19a41ec 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/LocalAssetServiceConnector.cs
@@ -208,6 +208,8 @@ namespace OpenSim.Region.CoreModules.ServiceConnectors.Asset
208 public string Store(AssetBase asset) 208 public string Store(AssetBase asset)
209 { 209 {
210 m_Cache.Cache(asset); 210 m_Cache.Cache(asset);
211 if (asset.Temporary || asset.Local)
212 return asset.ID;
211 return m_AssetService.Store(asset); 213 return m_AssetService.Store(asset);
212 } 214 }
213 215
diff --git a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs
index c409d15..4e8b5d6 100644
--- a/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs
+++ b/OpenSim/Region/CoreModules/ServiceConnectors/Asset/RemoteAssetServiceConnector.cs
@@ -230,6 +230,14 @@ namespace OpenSim.Region.CoreModules.ServiceConnectors.Asset
230 230
231 public string Store(AssetBase asset) 231 public string Store(AssetBase asset)
232 { 232 {
233 if (asset.Temporary || asset.Local)
234 {
235 if (m_Cache != null)
236 m_Cache.Cache(asset);
237
238 return asset.ID;
239 }
240
233 string uri = m_ServerURI + "/assets/"; 241 string uri = m_ServerURI + "/assets/";
234 242
235 string newID = SynchronousRestObjectRequester. 243 string newID = SynchronousRestObjectRequester.
@@ -237,6 +245,8 @@ namespace OpenSim.Region.CoreModules.ServiceConnectors.Asset
237 245
238 if (newID != String.Empty) 246 if (newID != String.Empty)
239 { 247 {
248 asset.ID = newID;
249
240 if (m_Cache != null) 250 if (m_Cache != null)
241 m_Cache.Cache(asset); 251 m_Cache.Cache(asset);
242 } 252 }