diff options
author | Diva Canto | 2010-08-16 14:36:20 -0700 |
---|---|---|
committer | Diva Canto | 2010-08-16 14:36:20 -0700 |
commit | d7824b86d97bf3b219b67c8908eb28ba0f3edbeb (patch) | |
tree | 26f44cadace21d2c07ea4fee503b239c0366d173 /OpenSim/Services | |
parent | Attempt at sending TeleportProgress, but it doesn't seem to be doing anything... (diff) | |
download | opensim-SC-d7824b86d97bf3b219b67c8908eb28ba0f3edbeb.zip opensim-SC-d7824b86d97bf3b219b67c8908eb28ba0f3edbeb.tar.gz opensim-SC-d7824b86d97bf3b219b67c8908eb28ba0f3edbeb.tar.bz2 opensim-SC-d7824b86d97bf3b219b67c8908eb28ba0f3edbeb.tar.xz |
Fixes mantis #4954 for the xml-rpc calls of the UserAgentServiceConnector. Basically, let's not let the xml-rpc library do the DNS conversion...
Diffstat (limited to 'OpenSim/Services')
-rw-r--r-- | OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs b/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs index 96d2605..69dff3c 100644 --- a/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs +++ b/OpenSim/Services/Connectors/Hypergrid/UserAgentServiceConnector.cs | |||
@@ -53,9 +53,20 @@ namespace OpenSim.Services.Connectors.Hypergrid | |||
53 | MethodBase.GetCurrentMethod().DeclaringType); | 53 | MethodBase.GetCurrentMethod().DeclaringType); |
54 | 54 | ||
55 | string m_ServerURL; | 55 | string m_ServerURL; |
56 | Uri m_Uri; | ||
56 | public UserAgentServiceConnector(string url) | 57 | public UserAgentServiceConnector(string url) |
57 | { | 58 | { |
58 | m_ServerURL = url; | 59 | m_ServerURL = url; |
60 | try | ||
61 | { | ||
62 | m_Uri = new Uri(m_ServerURL); | ||
63 | IPAddress ip = Util.GetHostFromDNS(m_Uri.Host); | ||
64 | m_ServerURL = "http://" + ip.ToString() + ":" + m_Uri.Port; | ||
65 | } | ||
66 | catch (Exception e) | ||
67 | { | ||
68 | m_log.DebugFormat("[USER AGENT CONNECTOR]: Malformed Uri {0}: {1}", m_ServerURL, e.Message); | ||
69 | } | ||
59 | } | 70 | } |
60 | 71 | ||
61 | public UserAgentServiceConnector(IConfigSource config) | 72 | public UserAgentServiceConnector(IConfigSource config) |
@@ -373,7 +384,7 @@ namespace OpenSim.Services.Connectors.Hypergrid | |||
373 | 384 | ||
374 | if (response.IsFault) | 385 | if (response.IsFault) |
375 | { | 386 | { |
376 | m_log.ErrorFormat("[HGrid]: remote call to {0} returned an error: {1}", m_ServerURL, response.FaultString); | 387 | m_log.ErrorFormat("[USER AGENT CONNECTOR]: remote call to {0} returned an error: {1}", m_ServerURL, response.FaultString); |
377 | reason = "XMLRPC Fault"; | 388 | reason = "XMLRPC Fault"; |
378 | return false; | 389 | return false; |
379 | } | 390 | } |
@@ -403,7 +414,7 @@ namespace OpenSim.Services.Connectors.Hypergrid | |||
403 | } | 414 | } |
404 | catch (Exception e) | 415 | catch (Exception e) |
405 | { | 416 | { |
406 | m_log.ErrorFormat("[HGrid]: Got exception on GetBoolResponse response."); | 417 | m_log.ErrorFormat("[USER AGENT CONNECTOR]: Got exception on GetBoolResponse response."); |
407 | if (hash.ContainsKey("result") && hash["result"] != null) | 418 | if (hash.ContainsKey("result") && hash["result"] != null) |
408 | m_log.ErrorFormat("Reply was ", (string)hash["result"]); | 419 | m_log.ErrorFormat("Reply was ", (string)hash["result"]); |
409 | reason = "Exception: " + e.Message; | 420 | reason = "Exception: " + e.Message; |