aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Application
diff options
context:
space:
mode:
authorlbsa712008-09-08 14:30:35 +0000
committerlbsa712008-09-08 14:30:35 +0000
commit8388fe0669f9d140028d1925284491b21a09a1bf (patch)
tree80c7729bef9b88a371c3f561322a97faf262ade6 /OpenSim/Region/Application
parentMantis #2144 (diff)
downloadopensim-SC-8388fe0669f9d140028d1925284491b21a09a1bf.zip
opensim-SC-8388fe0669f9d140028d1925284491b21a09a1bf.tar.gz
opensim-SC-8388fe0669f9d140028d1925284491b21a09a1bf.tar.bz2
opensim-SC-8388fe0669f9d140028d1925284491b21a09a1bf.tar.xz
* some if inversions and added {}'s for readability
Diffstat (limited to 'OpenSim/Region/Application')
-rw-r--r--OpenSim/Region/Application/Application.cs2
-rw-r--r--OpenSim/Region/Application/OpenSim.cs8
-rw-r--r--OpenSim/Region/Application/OpenSimBase.cs36
3 files changed, 35 insertions, 11 deletions
diff --git a/OpenSim/Region/Application/Application.cs b/OpenSim/Region/Application/Application.cs
index 59ac161..8d2ce55 100644
--- a/OpenSim/Region/Application/Application.cs
+++ b/OpenSim/Region/Application/Application.cs
@@ -117,7 +117,9 @@ namespace OpenSim
117 msg += "Exception: " + e.ExceptionObject.ToString() + "\r\n"; 117 msg += "Exception: " + e.ExceptionObject.ToString() + "\r\n";
118 Exception ex = (Exception)e.ExceptionObject; 118 Exception ex = (Exception)e.ExceptionObject;
119 if (ex.InnerException != null) 119 if (ex.InnerException != null)
120 {
120 msg += "InnerException: " + ex.InnerException.ToString() + "\r\n"; 121 msg += "InnerException: " + ex.InnerException.ToString() + "\r\n";
122 }
121 123
122 msg += "\r\n"; 124 msg += "\r\n";
123 msg += "Application is terminating: " + e.IsTerminating.ToString() + "\r\n"; 125 msg += "Application is terminating: " + e.IsTerminating.ToString() + "\r\n";
diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs
index edb29db..43c1d26 100644
--- a/OpenSim/Region/Application/OpenSim.cs
+++ b/OpenSim/Region/Application/OpenSim.cs
@@ -77,6 +77,7 @@ namespace OpenSim
77 77
78 m_timedScript = startupConfig.GetString("timer_Script", "disabled"); 78 m_timedScript = startupConfig.GetString("timer_Script", "disabled");
79 } 79 }
80
80 base.ReadConfigSettings(); 81 base.ReadConfigSettings();
81 } 82 }
82 83
@@ -96,13 +97,13 @@ namespace OpenSim
96 base.Startup(); 97 base.Startup();
97 98
98 //Run Startup Commands 99 //Run Startup Commands
99 if (m_startupCommandsFile != String.Empty) 100 if (String.IsNullOrEmpty( m_startupCommandsFile ))
100 { 101 {
101 RunCommandScript(m_startupCommandsFile); 102 m_log.Info("[STARTUP]: No startup command script specified. Moving on...");
102 } 103 }
103 else 104 else
104 { 105 {
105 m_log.Info("[STARTUP]: No startup command script specified. Moving on..."); 106 RunCommandScript(m_startupCommandsFile);
106 } 107 }
107 108
108 // Start timer script (run a script every xx seconds) 109 // Start timer script (run a script every xx seconds)
@@ -365,6 +366,7 @@ namespace OpenSim
365 { 366 {
366 m_sceneManager.TrySetCurrentScene(".."); 367 m_sceneManager.TrySetCurrentScene("..");
367 } 368 }
369
368 m_regionData.Remove(killScene.RegionInfo); 370 m_regionData.Remove(killScene.RegionInfo);
369 m_sceneManager.CloseScene(killScene); 371 m_sceneManager.CloseScene(killScene);
370 } 372 }
diff --git a/OpenSim/Region/Application/OpenSimBase.cs b/OpenSim/Region/Application/OpenSimBase.cs
index e2b2bbc..156d022 100644
--- a/OpenSim/Region/Application/OpenSimBase.cs
+++ b/OpenSim/Region/Application/OpenSimBase.cs
@@ -205,7 +205,10 @@ namespace OpenSim
205 { 205 {
206 IConfigSource DefaultConfig = new IniConfigSource(); 206 IConfigSource DefaultConfig = new IniConfigSource();
207 if (DefaultConfig.Configs["Startup"] == null) 207 if (DefaultConfig.Configs["Startup"] == null)
208 {
208 DefaultConfig.AddConfig("Startup"); 209 DefaultConfig.AddConfig("Startup");
210 }
211
209 IConfig config = DefaultConfig.Configs["Startup"]; 212 IConfig config = DefaultConfig.Configs["Startup"];
210 if (config != null) 213 if (config != null)
211 { 214 {
@@ -225,7 +228,9 @@ namespace OpenSim
225 } 228 }
226 229
227 if (DefaultConfig.Configs["StandAlone"] == null) 230 if (DefaultConfig.Configs["StandAlone"] == null)
231 {
228 DefaultConfig.AddConfig("StandAlone"); 232 DefaultConfig.AddConfig("StandAlone");
233 }
229 234
230 config = DefaultConfig.Configs["StandAlone"]; 235 config = DefaultConfig.Configs["StandAlone"];
231 if (config != null) 236 if (config != null)
@@ -242,7 +247,10 @@ namespace OpenSim
242 } 247 }
243 248
244 if (DefaultConfig.Configs["Network"] == null) 249 if (DefaultConfig.Configs["Network"] == null)
250 {
245 DefaultConfig.AddConfig("Network"); 251 DefaultConfig.AddConfig("Network");
252 }
253
246 config = DefaultConfig.Configs["Network"]; 254 config = DefaultConfig.Configs["Network"];
247 if (config != null) 255 if (config != null)
248 { 256 {
@@ -262,7 +270,10 @@ namespace OpenSim
262 } 270 }
263 271
264 if (DefaultConfig.Configs["RemoteAdmin"] == null) 272 if (DefaultConfig.Configs["RemoteAdmin"] == null)
273 {
265 DefaultConfig.AddConfig("RemoteAdmin"); 274 DefaultConfig.AddConfig("RemoteAdmin");
275 }
276
266 config = DefaultConfig.Configs["RemoteAdmin"]; 277 config = DefaultConfig.Configs["RemoteAdmin"];
267 if (config != null) 278 if (config != null)
268 { 279 {
@@ -270,12 +281,16 @@ namespace OpenSim
270 } 281 }
271 282
272 if (DefaultConfig.Configs["Voice"] == null) 283 if (DefaultConfig.Configs["Voice"] == null)
284 {
273 DefaultConfig.AddConfig("Voice"); 285 DefaultConfig.AddConfig("Voice");
286 }
287
274 config = DefaultConfig.Configs["Voice"]; 288 config = DefaultConfig.Configs["Voice"];
275 if (config != null) 289 if (config != null)
276 { 290 {
277 config.Set("enabled", "false"); 291 config.Set("enabled", "false");
278 } 292 }
293
279 return DefaultConfig; 294 return DefaultConfig;
280 295
281 } 296 }
@@ -741,18 +756,23 @@ namespace OpenSim
741 return; 756 return;
742 } 757 }
743 758
744 if (null != inventoryFolder) 759 if (null == inventoryFolder)
745 { 760 {
746 m_log.InfoFormat("[CONSOLE]: Found folder {0} {1} at {2}", inventoryFolder.Name, inventoryFolder.ID, invPath); 761 if (null == inventoryItem)
747 } 762 {
748 else if (null != inventoryItem) 763 m_log.ErrorFormat("[CONSOLE]: Could not find inventory entry at path {0}", invPath);
749 { 764 return;
750 m_log.InfoFormat("[CONSOLE]: Found item {0} {1} at {2}", inventoryItem.Name, inventoryItem.ID, invPath); 765 }
766 else
767 {
768 m_log.InfoFormat("[CONSOLE]: Found item {0} {1} at {2}", inventoryItem.Name, inventoryItem.ID,
769 invPath);
770 }
751 } 771 }
752 else 772 else
753 { 773 {
754 m_log.ErrorFormat("[CONSOLE]: Could not find inventory entry at path {0}", invPath); 774 m_log.InfoFormat("[CONSOLE]: Found folder {0} {1} at {2}", inventoryFolder.Name, inventoryFolder.ID,
755 return; 775 invPath);
756 } 776 }
757 } 777 }
758 778