mirror of
https://github.com/opensim/opensim.git
synced 2026-08-08 02:05:34 +08:00
add GetLocalRegionByName to GridServicesConnector plus cosmetics
This commit is contained in:
@@ -543,19 +543,21 @@ namespace OpenSim.Server.Base
|
||||
|
||||
public static Dictionary<string, object> ParseXmlResponse(string data)
|
||||
{
|
||||
try
|
||||
if(!string.IsNullOrEmpty(data))
|
||||
{
|
||||
using XmlReader xr = XmlReader.Create(new StringReader(data),
|
||||
ParseXmlStringResponseXmlReaderSettings, ParseXmlResponseXmlParserContext);
|
||||
if (!xr.ReadToFollowing("ServerResponse"))
|
||||
return new Dictionary<string, object>();
|
||||
return ScanXmlResponse(xr);
|
||||
try
|
||||
{
|
||||
using XmlReader xr = XmlReader.Create(new StringReader(data),
|
||||
ParseXmlStringResponseXmlReaderSettings, ParseXmlResponseXmlParserContext);
|
||||
if (xr.ReadToFollowing("ServerResponse"))
|
||||
return ScanXmlResponse(xr);
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
m_log.Debug($"[serverUtils.ParseXmlResponse]: failed error: {e.Message}\n --string:\n{data}\n");
|
||||
}
|
||||
}
|
||||
catch (Exception e)
|
||||
{
|
||||
m_log.DebugFormat("[serverUtils.ParseXmlResponse]: failed error: {0}\n --string:\n{1}\n", e.Message, data);
|
||||
}
|
||||
return new Dictionary<string, object>();
|
||||
return [];
|
||||
}
|
||||
|
||||
private static readonly XmlReaderSettings ParseXmlStreamResponseXmlReaderSettings = new()
|
||||
|
||||
Reference in New Issue
Block a user