aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework/Communications
diff options
context:
space:
mode:
authorJeff Ames2008-05-28 03:44:49 +0000
committerJeff Ames2008-05-28 03:44:49 +0000
commit5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4 (patch)
treeea980f49f1a6bb40ba037a87581a3d741c3d3c56 /OpenSim/Framework/Communications
parentThank you kindly, Melanie for a patch that: (diff)
downloadopensim-SC_OLD-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.zip
opensim-SC_OLD-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.tar.gz
opensim-SC_OLD-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.tar.bz2
opensim-SC_OLD-5752c1f5c2ee069e2ff5ffc0ff2f186d7454c5c4.tar.xz
Formatting cleanup.
Diffstat (limited to 'OpenSim/Framework/Communications')
-rw-r--r--OpenSim/Framework/Communications/Cache/AssetCache.cs20
-rw-r--r--OpenSim/Framework/Communications/Cache/CachedUserInfo.cs10
2 files changed, 15 insertions, 15 deletions
diff --git a/OpenSim/Framework/Communications/Cache/AssetCache.cs b/OpenSim/Framework/Communications/Cache/AssetCache.cs
index feac65a..dcb7d73 100644
--- a/OpenSim/Framework/Communications/Cache/AssetCache.cs
+++ b/OpenSim/Framework/Communications/Cache/AssetCache.cs
@@ -249,11 +249,11 @@ namespace OpenSim.Framework.Communications.Cache
249 //m_log.DebugFormat("[ASSET CACHE]: Requesting {0} {1}", isTexture ? "texture" : "asset", assetId); 249 //m_log.DebugFormat("[ASSET CACHE]: Requesting {0} {1}", isTexture ? "texture" : "asset", assetId);
250 250
251 251
252 // Xantor 20080526: 252 // Xantor 20080526:
253 // if a request is made for an asset which is not in the cache yet, but has already been requested by 253 // if a request is made for an asset which is not in the cache yet, but has already been requested by
254 // something else, queue up the callbacks on that requestor instead of swamping the assetserver 254 // something else, queue up the callbacks on that requestor instead of swamping the assetserver
255 // with multiple requests for the same asset. 255 // with multiple requests for the same asset.
256 256
257 AssetBase asset; 257 AssetBase asset;
258 258
259 if (TryGetCachedAsset(assetId, out asset)) 259 if (TryGetCachedAsset(assetId, out asset))
@@ -265,8 +265,8 @@ namespace OpenSim.Framework.Communications.Cache
265#if DEBUG 265#if DEBUG
266 // m_log.DebugFormat("[ASSET CACHE]: Adding request for {0} {1}", isTexture ? "texture" : "asset", assetId); 266 // m_log.DebugFormat("[ASSET CACHE]: Adding request for {0} {1}", isTexture ? "texture" : "asset", assetId);
267#endif 267#endif
268 268
269 269
270 NewAssetRequest req = new NewAssetRequest(assetId, callback); 270 NewAssetRequest req = new NewAssetRequest(assetId, callback);
271 AssetRequestsList requestList; 271 AssetRequestsList requestList;
272 272
@@ -499,7 +499,7 @@ namespace OpenSim.Framework.Communications.Cache
499 { 499 {
500 Assets[assetID] = null; 500 Assets[assetID] = null;
501 } 501 }
502 502
503 // Notify requesters for this asset 503 // Notify requesters for this asset
504 AssetRequestsList reqList = null; 504 AssetRequestsList reqList = null;
505 lock (RequestLists) 505 lock (RequestLists)
@@ -590,20 +590,20 @@ namespace OpenSim.Framework.Communications.Cache
590 RequestedAssets.Add(requestID, request); 590 RequestedAssets.Add(requestID, request);
591 m_assetServer.RequestAsset(requestID, false); 591 m_assetServer.RequestAsset(requestID, false);
592 } 592 }
593 593
594 return; 594 return;
595 } 595 }
596 596
597 // It has an entry in our cache 597 // It has an entry in our cache
598 AssetInfo asset = Assets[requestID]; 598 AssetInfo asset = Assets[requestID];
599 599
600 // FIXME: We never tell the client about assets which do not exist when requested by this transfer mechanism, which can't be right. 600 // FIXME: We never tell the client about assets which do not exist when requested by this transfer mechanism, which can't be right.
601 if (null == asset) 601 if (null == asset)
602 { 602 {
603 //m_log.DebugFormat("[ASSET CACHE]: Asset transfer request for asset which is {0} already known to be missing. Dropping", requestID); 603 //m_log.DebugFormat("[ASSET CACHE]: Asset transfer request for asset which is {0} already known to be missing. Dropping", requestID);
604 return; 604 return;
605 } 605 }
606 606
607 // The asset is knosn to exist and is in our cache, so add it to the AssetRequests list 607 // The asset is knosn to exist and is in our cache, so add it to the AssetRequests list
608 AssetRequest req = new AssetRequest(); 608 AssetRequest req = new AssetRequest();
609 req.RequestUser = userInfo; 609 req.RequestUser = userInfo;
diff --git a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs
index 1cbffc7..b98cec7 100644
--- a/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs
+++ b/OpenSim/Framework/Communications/Cache/CachedUserInfo.cs
@@ -485,10 +485,10 @@ namespace OpenSim.Framework.Communications.Cache
485 { 485 {
486 if (HasInventory) 486 if (HasInventory)
487 { 487 {
488 if(item.Folder == LLUUID.Zero) 488 if (item.Folder == LLUUID.Zero)
489 { 489 {
490 InventoryFolderImpl f=FindFolderForType(item.AssetType); 490 InventoryFolderImpl f=FindFolderForType(item.AssetType);
491 if(f != null) 491 if (f != null)
492 item.Folder=f.ID; 492 item.Folder=f.ID;
493 else 493 else
494 item.Folder=RootFolder.ID; 494 item.Folder=RootFolder.ID;
@@ -617,14 +617,14 @@ namespace OpenSim.Framework.Communications.Cache
617 617
618 private InventoryFolderImpl FindFolderForType(int type) 618 private InventoryFolderImpl FindFolderForType(int type)
619 { 619 {
620 if(RootFolder == null) 620 if (RootFolder == null)
621 return null; 621 return null;
622 622
623 lock(RootFolder.SubFolders) 623 lock (RootFolder.SubFolders)
624 { 624 {
625 foreach (InventoryFolderImpl f in RootFolder.SubFolders.Values) 625 foreach (InventoryFolderImpl f in RootFolder.SubFolders.Values)
626 { 626 {
627 if(f.Type == type) 627 if (f.Type == type)
628 return f; 628 return f;
629 } 629 }
630 } 630 }