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=6556user_profiles
parent
aadf7d32d1
commit
fa9f4ef1ba
|
@ -57,7 +57,6 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
public bool Enabled { get; private set; }
|
public bool Enabled { get; private set; }
|
||||||
|
|
||||||
private Scene m_scene;
|
private Scene m_scene;
|
||||||
private UUID m_agentID;
|
|
||||||
|
|
||||||
#region ISharedRegionModule Members
|
#region ISharedRegionModule Members
|
||||||
|
|
||||||
|
@ -118,25 +117,26 @@ namespace OpenSim.Region.ClientStack.Linden
|
||||||
public void RegisterCaps(UUID agentID, Caps caps)
|
public void RegisterCaps(UUID agentID, Caps caps)
|
||||||
{
|
{
|
||||||
IRequestHandler reqHandler
|
IRequestHandler reqHandler
|
||||||
= new RestHTTPHandler("GET", "/CAPS/" + UUID.Random(), MeshUploadFlag, "MeshUploadFlag", agentID.ToString());
|
= new RestHTTPHandler(
|
||||||
|
"GET", "/CAPS/" + UUID.Random(), ht => MeshUploadFlag(ht, agentID), "MeshUploadFlag", agentID.ToString());
|
||||||
|
|
||||||
caps.RegisterHandler("MeshUploadFlag", reqHandler);
|
caps.RegisterHandler("MeshUploadFlag", reqHandler);
|
||||||
m_agentID = agentID;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
private Hashtable MeshUploadFlag(Hashtable mDhttpMethod)
|
private Hashtable MeshUploadFlag(Hashtable mDhttpMethod, UUID agentID)
|
||||||
{
|
{
|
||||||
// m_log.DebugFormat("[MESH UPLOAD FLAG MODULE]: MeshUploadFlag request");
|
// m_log.DebugFormat("[MESH UPLOAD FLAG MODULE]: MeshUploadFlag request");
|
||||||
|
|
||||||
OSDMap data = new OSDMap();
|
OSDMap data = new OSDMap();
|
||||||
ScenePresence sp = m_scene.GetScenePresence(m_agentID);
|
ScenePresence sp = m_scene.GetScenePresence(agentID);
|
||||||
data["username"] = sp.Firstname + "." + sp.Lastname;
|
data["username"] = sp.Firstname + "." + sp.Lastname;
|
||||||
data["display_name_next_update"] = new OSDDate(DateTime.Now);
|
data["display_name_next_update"] = new OSDDate(DateTime.Now);
|
||||||
data["legacy_first_name"] = sp.Firstname;
|
data["legacy_first_name"] = sp.Firstname;
|
||||||
data["mesh_upload_status"] = "valid";
|
data["mesh_upload_status"] = "valid";
|
||||||
data["display_name"] = sp.Firstname + " " + sp.Lastname;
|
data["display_name"] = sp.Firstname + " " + sp.Lastname;
|
||||||
data["legacy_last_name"] = sp.Lastname;
|
data["legacy_last_name"] = sp.Lastname;
|
||||||
data["id"] = m_agentID;
|
data["id"] = agentID;
|
||||||
data["is_display_name_default"] = true;
|
data["is_display_name_default"] = true;
|
||||||
|
|
||||||
//Send back data
|
//Send back data
|
||||||
|
|
Loading…
Reference in New Issue