diff options
author | Justin Clark-Casey (justincc) | 2013-03-04 23:20:00 +0000 |
---|---|---|
committer | Justin Clark-Casey (justincc) | 2013-03-04 23:20:00 +0000 |
commit | fa9f4ef1baca14ed4ee20712219932f1e6e09990 (patch) | |
tree | 1b146508fc54439ae9705136b0a96f5b9a6761e8 /OpenSim/Region | |
parent | GridUserService was missing from [Gatekeeper] (diff) | |
download | opensim-SC-fa9f4ef1baca14ed4ee20712219932f1e6e09990.zip opensim-SC-fa9f4ef1baca14ed4ee20712219932f1e6e09990.tar.gz opensim-SC-fa9f4ef1baca14ed4ee20712219932f1e6e09990.tar.bz2 opensim-SC-fa9f4ef1baca14ed4ee20712219932f1e6e09990.tar.xz |
Fix issue in the mesh upload flag module where the ID of the last agent to request the capability was always used instead of the original requesting agent for each cap.
Should address http://opensimulator.org/mantis/view.php?id=6556
Diffstat (limited to 'OpenSim/Region')
-rw-r--r-- | OpenSim/Region/ClientStack/Linden/Caps/MeshUploadFlagModule.cs | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/OpenSim/Region/ClientStack/Linden/Caps/MeshUploadFlagModule.cs b/OpenSim/Region/ClientStack/Linden/Caps/MeshUploadFlagModule.cs index 33b1f77..45d33cd 100644 --- a/OpenSim/Region/ClientStack/Linden/Caps/MeshUploadFlagModule.cs +++ b/OpenSim/Region/ClientStack/Linden/Caps/MeshUploadFlagModule.cs | |||
@@ -57,7 +57,6 @@ namespace OpenSim.Region.ClientStack.Linden | |||
57 | public bool Enabled { get; private set; } | 57 | public bool Enabled { get; private set; } |
58 | 58 | ||
59 | private Scene m_scene; | 59 | private Scene m_scene; |
60 | private UUID m_agentID; | ||
61 | 60 | ||
62 | #region ISharedRegionModule Members | 61 | #region ISharedRegionModule Members |
63 | 62 | ||
@@ -118,25 +117,26 @@ namespace OpenSim.Region.ClientStack.Linden | |||
118 | public void RegisterCaps(UUID agentID, Caps caps) | 117 | public void RegisterCaps(UUID agentID, Caps caps) |
119 | { | 118 | { |
120 | IRequestHandler reqHandler | 119 | IRequestHandler reqHandler |
121 | = new RestHTTPHandler("GET", "/CAPS/" + UUID.Random(), MeshUploadFlag, "MeshUploadFlag", agentID.ToString()); | 120 | = new RestHTTPHandler( |
121 | "GET", "/CAPS/" + UUID.Random(), ht => MeshUploadFlag(ht, agentID), "MeshUploadFlag", agentID.ToString()); | ||
122 | 122 | ||
123 | caps.RegisterHandler("MeshUploadFlag", reqHandler); | 123 | caps.RegisterHandler("MeshUploadFlag", reqHandler); |
124 | m_agentID = agentID; | 124 | |
125 | } | 125 | } |
126 | 126 | ||
127 | private Hashtable MeshUploadFlag(Hashtable mDhttpMethod) | 127 | private Hashtable MeshUploadFlag(Hashtable mDhttpMethod, UUID agentID) |
128 | { | 128 | { |
129 | // m_log.DebugFormat("[MESH UPLOAD FLAG MODULE]: MeshUploadFlag request"); | 129 | // m_log.DebugFormat("[MESH UPLOAD FLAG MODULE]: MeshUploadFlag request"); |
130 | 130 | ||
131 | OSDMap data = new OSDMap(); | 131 | OSDMap data = new OSDMap(); |
132 | ScenePresence sp = m_scene.GetScenePresence(m_agentID); | 132 | ScenePresence sp = m_scene.GetScenePresence(agentID); |
133 | data["username"] = sp.Firstname + "." + sp.Lastname; | 133 | data["username"] = sp.Firstname + "." + sp.Lastname; |
134 | data["display_name_next_update"] = new OSDDate(DateTime.Now); | 134 | data["display_name_next_update"] = new OSDDate(DateTime.Now); |
135 | data["legacy_first_name"] = sp.Firstname; | 135 | data["legacy_first_name"] = sp.Firstname; |
136 | data["mesh_upload_status"] = "valid"; | 136 | data["mesh_upload_status"] = "valid"; |
137 | data["display_name"] = sp.Firstname + " " + sp.Lastname; | 137 | data["display_name"] = sp.Firstname + " " + sp.Lastname; |
138 | data["legacy_last_name"] = sp.Lastname; | 138 | data["legacy_last_name"] = sp.Lastname; |
139 | data["id"] = m_agentID; | 139 | data["id"] = agentID; |
140 | data["is_display_name_default"] = true; | 140 | data["is_display_name_default"] = true; |
141 | 141 | ||
142 | //Send back data | 142 | //Send back data |