diff options
author | Justin Clarke Casey | 2008-02-20 17:34:10 +0000 |
---|---|---|
committer | Justin Clarke Casey | 2008-02-20 17:34:10 +0000 |
commit | 877713999ce9bcf63e9fafa76cc7d2283ee2e6c2 (patch) | |
tree | a777abaadb3556af6933a5ac6fa85af6647629ed /OpenSim/Region/Environment/Modules | |
parent | llSetTimerEvent was setting seconds as milliseconds causing major problems in... (diff) | |
download | opensim-SC_OLD-877713999ce9bcf63e9fafa76cc7d2283ee2e6c2.zip opensim-SC_OLD-877713999ce9bcf63e9fafa76cc7d2283ee2e6c2.tar.gz opensim-SC_OLD-877713999ce9bcf63e9fafa76cc7d2283ee2e6c2.tar.bz2 opensim-SC_OLD-877713999ce9bcf63e9fafa76cc7d2283ee2e6c2.tar.xz |
* Report 'asset not found' situations back to UserTextureDownloadService
* This fixes some of the 'runaway downloads' problem but not all of it
* Also fix up logging messages so texture requests are reported as such rather than as assets
Diffstat (limited to 'OpenSim/Region/Environment/Modules')
-rw-r--r-- | OpenSim/Region/Environment/Modules/UserTextureDownloadService.cs | 24 |
1 files changed, 19 insertions, 5 deletions
diff --git a/OpenSim/Region/Environment/Modules/UserTextureDownloadService.cs b/OpenSim/Region/Environment/Modules/UserTextureDownloadService.cs index 4a94266..24f0981 100644 --- a/OpenSim/Region/Environment/Modules/UserTextureDownloadService.cs +++ b/OpenSim/Region/Environment/Modules/UserTextureDownloadService.cs | |||
@@ -95,7 +95,7 @@ namespace OpenSim.Region.Environment.Modules | |||
95 | new TextureSender(client, e.DiscardLevel, e.PacketNumber); | 95 | new TextureSender(client, e.DiscardLevel, e.PacketNumber); |
96 | m_textureSenders.Add(e.RequestedAssetID, requestHandler); | 96 | m_textureSenders.Add(e.RequestedAssetID, requestHandler); |
97 | 97 | ||
98 | m_scene.AssetCache.GetAsset(e.RequestedAssetID, TextureCallback); | 98 | m_scene.AssetCache.GetAsset(e.RequestedAssetID, TextureCallback, true); |
99 | } | 99 | } |
100 | } | 100 | } |
101 | } | 101 | } |
@@ -117,7 +117,7 @@ namespace OpenSim.Region.Environment.Modules | |||
117 | /// </summary> | 117 | /// </summary> |
118 | /// <param name="textureID"></param> | 118 | /// <param name="textureID"></param> |
119 | /// <param name="asset"></param> | 119 | /// <param name="asset"></param> |
120 | public void TextureCallback(LLUUID textureID, AssetBase asset) | 120 | public void TextureCallback(LLUUID textureID, AssetBase texture) |
121 | { | 121 | { |
122 | lock (m_textureSenders) | 122 | lock (m_textureSenders) |
123 | { | 123 | { |
@@ -125,10 +125,24 @@ namespace OpenSim.Region.Environment.Modules | |||
125 | 125 | ||
126 | if (m_textureSenders.TryGetValue(textureID, out textureSender)) | 126 | if (m_textureSenders.TryGetValue(textureID, out textureSender)) |
127 | { | 127 | { |
128 | if (!textureSender.ImageLoaded) | 128 | if (null != texture) |
129 | { | 129 | { |
130 | textureSender.TextureReceived(asset); | 130 | if (!textureSender.ImageLoaded) |
131 | EnqueueTextureSender(textureSender); | 131 | { |
132 | textureSender.TextureReceived(texture); | ||
133 | EnqueueTextureSender(textureSender); | ||
134 | } | ||
135 | } | ||
136 | else | ||
137 | { | ||
138 | // Right now, leaving it up to lower level asset server code to post the fact that | ||
139 | // this texture could not be found | ||
140 | |||
141 | // TODO Send packet back to the client telling it not to expect the texture | ||
142 | // The absence of this packet doesn't appear to be causing it a problem right now | ||
143 | |||
144 | //m_log.InfoFormat("Removing {0} from pending downloads count", textureID); | ||
145 | m_scene.AddPendingDownloads(-1); | ||
132 | } | 146 | } |
133 | 147 | ||
134 | //m_log.InfoFormat("[TEXTURE SENDER] Removing texture sender with uuid {0}", textureID); | 148 | //m_log.InfoFormat("[TEXTURE SENDER] Removing texture sender with uuid {0}", textureID); |