Fix CAPS to work like they should - do not send caps to the viewer if they're not in the requested caps list.

The previous wrong behavior caused the debug setting "UseHTTPInventory" to fail
on all viewers when turned off. UDB inventory would not be correctly used in
that case.
This commit is contained in:
Melanie
2013-04-30 23:35:59 +02:00
parent 14f78c2e66
commit 0af1d8fe19
3 changed files with 18 additions and 4 deletions

View File

@@ -158,7 +158,7 @@ namespace OpenSim.Framework.Capabilities
/// capabilities and their handler details.
/// </summary>
/// <param name="excludeSeed">If true, then exclude the seed cap.</param>
public Hashtable GetCapsDetails(bool excludeSeed)
public Hashtable GetCapsDetails(bool excludeSeed, List<string> requestedCaps)
{
Hashtable caps = new Hashtable();
string protocol = "http://";
@@ -175,6 +175,9 @@ namespace OpenSim.Framework.Capabilities
if (excludeSeed && "SEED" == capsName)
continue;
if (requestedCaps != null && !requestedCaps.Contains(capsName))
continue;
caps[capsName] = baseUrl + m_capsHandlers[capsName].Path;
}
}
@@ -182,4 +185,4 @@ namespace OpenSim.Framework.Capabilities
return caps;
}
}
}
}