diff --git a/CurrentPatches/0001-Add-External-Hostname-DYNDNSIP-to-call-current-exter.patch b/CurrentPatches/0001-Add-External-Hostname-DYNDNSIP-to-call-current-exter.patch index 830c7c9..f558081 100644 --- a/CurrentPatches/0001-Add-External-Hostname-DYNDNSIP-to-call-current-exter.patch +++ b/CurrentPatches/0001-Add-External-Hostname-DYNDNSIP-to-call-current-exter.patch @@ -1,18 +1,18 @@ -From affb6e69909f26090497e8e3dae11544c269cd27 Mon Sep 17 00:00:00 2001 +From 6f363359d89cf5835d2fc32bedbdd89faf1311d1 Mon Sep 17 00:00:00 2001 From: Christopher -Date: Fri, 18 Mar 2022 12:52:23 +0100 +Date: Fri, 18 Mar 2022 13:55:34 +0100 Subject: [PATCH] Add External Hostname == DYNDNSIP to call current external ip from aws services --- - OpenSim/Framework/RegionInfo.cs | 20 ++++++++++++++++++++ - 1 file changed, 20 insertions(+) + OpenSim/Framework/RegionInfo.cs | 24 ++++++++++++++++++++++++ + 1 file changed, 24 insertions(+) diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs -index 507c51852b..4282fe06c0 100755 +index 507c51852b..f3bc127d54 100755 --- a/OpenSim/Framework/RegionInfo.cs +++ b/OpenSim/Framework/RegionInfo.cs -@@ -596,6 +596,26 @@ namespace OpenSim.Framework +@@ -596,6 +596,30 @@ namespace OpenSim.Framework m_log.InfoFormat( "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}", m_externalHostName, name); @@ -24,17 +24,21 @@ index 507c51852b..4282fe06c0 100755 + { + using (WebClient getIpClient = new WebClient()) + { -+ m_externalHostName = getIpClient.DownloadString("http://checkip.amazonaws.com/"); ++ String externalip = getIpClient.DownloadString("http://checkip.amazonaws.com/"); + -+ m_log.InfoFormat( -+ "[REGIONINFO]: Resolving DYNDNSIP to {0} for region {1}", -+ m_externalHostName, name); ++ if (externalip != null) ++ { ++ m_externalHostName = externalip.Trim(); ++ m_log.InfoFormat("[REGIONINFO]: Resolving DYNDNSIP to {0} for region {1}", m_externalHostName, name); ++ } ++ else ++ { ++ m_log.ErrorFormat("[REGIONINFO]: Resolving DYNDNSIP failed for region {0}", name); ++ } + } + }catch(Exception error) + { -+ m_log.ErrorFormat( -+ "[REGIONINFO]: Resolving DYNDNSIP failed for region {0}: {1}", -+ name, error.Message); ++ m_log.ErrorFormat("[REGIONINFO]: Resolving DYNDNSIP failed for region {0}: {1}", name, error.Message); + } } else if (!m_resolveAddress)