aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Framework
diff options
context:
space:
mode:
Diffstat (limited to 'OpenSim/Framework')
-rwxr-xr-xOpenSim/Framework/RegionInfo.cs21
1 files changed, 17 insertions, 4 deletions
diff --git a/OpenSim/Framework/RegionInfo.cs b/OpenSim/Framework/RegionInfo.cs
index 5a3b814..b88d31f 100755
--- a/OpenSim/Framework/RegionInfo.cs
+++ b/OpenSim/Framework/RegionInfo.cs
@@ -198,6 +198,11 @@ namespace OpenSim.Framework
198 { 198 {
199 // m_configSource = configSource; 199 // m_configSource = configSource;
200 CacheID = UUID.Random(); 200 CacheID = UUID.Random();
201 if (string.Empty == filename)
202 {
203 ReadNiniConfig(configSource, "Region", configName);
204 return;
205 }
201 206
202 if (filename.ToLower().EndsWith(".ini")) 207 if (filename.ToLower().EndsWith(".ini"))
203 { 208 {
@@ -425,7 +430,7 @@ namespace OpenSim.Framework
425 set { m_remotingPort = value; } 430 set { m_remotingPort = value; }
426 } 431 }
427 432
428 433
429 /// <value> 434 /// <value>
430 /// This accessor can throw all the exceptions that Dns.GetHostAddresses can throw. 435 /// This accessor can throw all the exceptions that Dns.GetHostAddresses can throw.
431 /// 436 ///
@@ -514,6 +519,10 @@ namespace OpenSim.Framework
514 519
515 private void ReadNiniConfig(IConfigSource source, string name) 520 private void ReadNiniConfig(IConfigSource source, string name)
516 { 521 {
522 ReadNiniConfig(source, name, name);
523 }
524 private void ReadNiniConfig(IConfigSource source, string section, string name)
525 {
517 bool creatingNew = false; 526 bool creatingNew = false;
518 527
519 if (source.Configs.Count == 0) 528 if (source.Configs.Count == 0)
@@ -549,8 +558,7 @@ namespace OpenSim.Framework
549 source.AddConfig(name); 558 source.AddConfig(name);
550 } 559 }
551 560
552 RegionName = name; 561 IConfig config = source.Configs[section];
553 IConfig config = source.Configs[name];
554 562
555 // Track all of the keys in this config and remove as they are processed 563 // Track all of the keys in this config and remove as they are processed
556 // The remaining keys will be added to generic key-value storage for 564 // The remaining keys will be added to generic key-value storage for
@@ -561,6 +569,11 @@ namespace OpenSim.Framework
561 allKeys.Add(s); 569 allKeys.Add(s);
562 } 570 }
563 571
572 // RegionName
573 //
574 allKeys.Remove("RegionName");
575 RegionName = config.GetString("RegionName", name);
576
564 // RegionUUID 577 // RegionUUID
565 // 578 //
566 allKeys.Remove("RegionUUID"); 579 allKeys.Remove("RegionUUID");
@@ -675,7 +688,7 @@ namespace OpenSim.Framework
675 m_externalHostName = Util.GetLocalHost().ToString(); 688 m_externalHostName = Util.GetLocalHost().ToString();
676 m_log.InfoFormat( 689 m_log.InfoFormat(
677 "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}", 690 "[REGIONINFO]: Resolving SYSTEMIP to {0} for external hostname of region {1}",
678 m_externalHostName, name); 691 m_externalHostName, RegionName);
679 } 692 }
680 else if (!m_resolveAddress) 693 else if (!m_resolveAddress)
681 { 694 {