diff options
author | Justin Clark-Casey (justincc) | 2011-12-08 23:45:53 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2011-12-08 23:45:53 +0000 |
commit | 63fe673af1974e265c5d18dc95f963fd968afd26 (patch) | |
tree | 91a5ede9b13be2e5538421ffa6821dc9f1d19777 /OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs | |
parent | Don't reply with an ack packet if the client is not authorized. (diff) | |
download | opensim-SC-63fe673af1974e265c5d18dc95f963fd968afd26.zip opensim-SC-63fe673af1974e265c5d18dc95f963fd968afd26.tar.gz opensim-SC-63fe673af1974e265c5d18dc95f963fd968afd26.tar.bz2 opensim-SC-63fe673af1974e265c5d18dc95f963fd968afd26.tar.xz |
Revert "Revert "Stop performing the asset save part of baked texture uploading on the UploadBakedTexture cap asynchronously.""
This turned out not to be the upload texture issue.
This reverts commit 8721841fc3944ce0cdf5ce76297e73f9ed269751.
Diffstat (limited to 'OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs')
-rw-r--r-- | OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs b/OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs index b7ca703..c637ccf 100644 --- a/OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs +++ b/OpenSim/Capabilities/Handlers/UploadBakedTexture/UploadBakedTextureHandler.cs | |||
@@ -104,7 +104,7 @@ namespace OpenSim.Capabilities.Handlers | |||
104 | } | 104 | } |
105 | catch (Exception e) | 105 | catch (Exception e) |
106 | { | 106 | { |
107 | m_log.Error("[CAPS]: " + e.ToString()); | 107 | m_log.Error("[UPLOAD BAKED TEXTURE HANDLER]: " + e.ToString()); |
108 | } | 108 | } |
109 | 109 | ||
110 | return null; | 110 | return null; |
@@ -130,6 +130,8 @@ namespace OpenSim.Capabilities.Handlers | |||
130 | 130 | ||
131 | class BakedTextureUploader | 131 | class BakedTextureUploader |
132 | { | 132 | { |
133 | // private static readonly ILog m_log = LogManager.GetLogger(MethodBase.GetCurrentMethod().DeclaringType); | ||
134 | |||
133 | public event Action<UUID, byte[]> OnUpLoad; | 135 | public event Action<UUID, byte[]> OnUpLoad; |
134 | 136 | ||
135 | private string uploaderPath = String.Empty; | 137 | private string uploaderPath = String.Empty; |
@@ -154,10 +156,12 @@ namespace OpenSim.Capabilities.Handlers | |||
154 | public string uploaderCaps(byte[] data, string path, string param) | 156 | public string uploaderCaps(byte[] data, string path, string param) |
155 | { | 157 | { |
156 | Action<UUID, byte[]> handlerUpLoad = OnUpLoad; | 158 | Action<UUID, byte[]> handlerUpLoad = OnUpLoad; |
159 | |||
160 | // Don't do this asynchronously, otherwise it's possible for the client to send set appearance information | ||
161 | // on another thread which might send out avatar updates before the asset has been put into the asset | ||
162 | // service. | ||
157 | if (handlerUpLoad != null) | 163 | if (handlerUpLoad != null) |
158 | { | 164 | handlerUpLoad(newAssetID, data); |
159 | Util.FireAndForget(delegate(object o) { handlerUpLoad(newAssetID, data); }); | ||
160 | } | ||
161 | 165 | ||
162 | string res = String.Empty; | 166 | string res = String.Empty; |
163 | LLSDAssetUploadComplete uploadComplete = new LLSDAssetUploadComplete(); | 167 | LLSDAssetUploadComplete uploadComplete = new LLSDAssetUploadComplete(); |
@@ -169,7 +173,7 @@ namespace OpenSim.Capabilities.Handlers | |||
169 | 173 | ||
170 | httpListener.RemoveStreamHandler("POST", uploaderPath); | 174 | httpListener.RemoveStreamHandler("POST", uploaderPath); |
171 | 175 | ||
172 | // m_log.InfoFormat("[CAPS] baked texture upload completed for {0}",newAssetID); | 176 | // m_log.DebugFormat("[BAKED TEXTURE UPLOADER]: baked texture upload completed for {0}", newAssetID); |
173 | 177 | ||
174 | return res; | 178 | return res; |
175 | } | 179 | } |