aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/OpenSim/Region/Application
diff options
context:
space:
mode:
authorJeff Ames2008-08-18 00:39:10 +0000
committerJeff Ames2008-08-18 00:39:10 +0000
commit6ef9d4da901a346c232458317cca6268da888e2e (patch)
treedd1d935b10f34f261839da9f9879c02322e8ede7 /OpenSim/Region/Application
parentUpdate svn properties, minor formatting cleanup. (diff)
downloadopensim-SC_OLD-6ef9d4da901a346c232458317cca6268da888e2e.zip
opensim-SC_OLD-6ef9d4da901a346c232458317cca6268da888e2e.tar.gz
opensim-SC_OLD-6ef9d4da901a346c232458317cca6268da888e2e.tar.bz2
opensim-SC_OLD-6ef9d4da901a346c232458317cca6268da888e2e.tar.xz
Formatting cleanup.
Diffstat (limited to 'OpenSim/Region/Application')
-rw-r--r--OpenSim/Region/Application/Application.cs2
-rw-r--r--OpenSim/Region/Application/IApplicationPlugin.cs2
-rw-r--r--OpenSim/Region/Application/OpenSim.cs92
-rw-r--r--OpenSim/Region/Application/OpenSimBase.cs50
4 files changed, 73 insertions, 73 deletions
diff --git a/OpenSim/Region/Application/Application.cs b/OpenSim/Region/Application/Application.cs
index 4df6415..59ac161 100644
--- a/OpenSim/Region/Application/Application.cs
+++ b/OpenSim/Region/Application/Application.cs
@@ -95,7 +95,7 @@ namespace OpenSim
95 } 95 }
96 96
97 private static bool _IsHandlingException = false; // Make sure we don't go recursive on ourself 97 private static bool _IsHandlingException = false; // Make sure we don't go recursive on ourself
98 98
99 /// <summary> 99 /// <summary>
100 /// Global exception handler -- all unhandlet exceptions end up here :) 100 /// Global exception handler -- all unhandlet exceptions end up here :)
101 /// </summary> 101 /// </summary>
diff --git a/OpenSim/Region/Application/IApplicationPlugin.cs b/OpenSim/Region/Application/IApplicationPlugin.cs
index 2e3122f..4fd93e8 100644
--- a/OpenSim/Region/Application/IApplicationPlugin.cs
+++ b/OpenSim/Region/Application/IApplicationPlugin.cs
@@ -33,7 +33,7 @@ namespace OpenSim
33 { 33 {
34 void Initialise(OpenSimBase openSim); 34 void Initialise(OpenSimBase openSim);
35 } 35 }
36 36
37 public class ApplicationPluginInitialiser : PluginInitialiserBase 37 public class ApplicationPluginInitialiser : PluginInitialiserBase
38 { 38 {
39 private OpenSimBase server; 39 private OpenSimBase server;
diff --git a/OpenSim/Region/Application/OpenSim.cs b/OpenSim/Region/Application/OpenSim.cs
index 4664b0b..cc2d993 100644
--- a/OpenSim/Region/Application/OpenSim.cs
+++ b/OpenSim/Region/Application/OpenSim.cs
@@ -90,8 +90,8 @@ namespace OpenSim
90 m_log.InfoFormat("[OPENSIM MAIN]: Running in {0} mode", (m_sandbox ? "sandbox" : "grid")); 90 m_log.InfoFormat("[OPENSIM MAIN]: Running in {0} mode", (m_sandbox ? "sandbox" : "grid"));
91 91
92 m_console = new ConsoleBase("Region", this); 92 m_console = new ConsoleBase("Region", this);
93 MainConsole.Instance = m_console; 93 MainConsole.Instance = m_console;
94 94
95 base.Startup(); 95 base.Startup();
96 96
97 //Run Startup Commands 97 //Run Startup Commands
@@ -116,9 +116,9 @@ namespace OpenSim
116 PrintFileToConsole("startuplogo.txt"); 116 PrintFileToConsole("startuplogo.txt");
117 RegisterCmd("echoTest", RunEchoTest, "this echos your command args to see how they are parsed"); 117 RegisterCmd("echoTest", RunEchoTest, "this echos your command args to see how they are parsed");
118 RegisterCmd("kickuser", KickUserCommand, "kickuser [first] [last] - attempts to log off a user from any region we are serving"); 118 RegisterCmd("kickuser", KickUserCommand, "kickuser [first] [last] - attempts to log off a user from any region we are serving");
119 119
120 // For now, start at the 'root' level by default 120 // For now, start at the 'root' level by default
121 ChangeSelectedRegion(new string[] {"root"}); 121 ChangeSelectedRegion(new string[] {"root"});
122 } 122 }
123 123
124 private void RunAutoTimerScript(object sender, EventArgs e) 124 private void RunAutoTimerScript(object sender, EventArgs e)
@@ -135,7 +135,7 @@ namespace OpenSim
135 { 135 {
136 for (int i = 0; i < cmdparams.Length; i++) 136 for (int i = 0; i < cmdparams.Length; i++)
137 { 137 {
138 m_log.Info("[EchoTest]: <arg" + i + ">"+cmdparams[i]+"</arg" + i + ">"); 138 m_log.Info("[EchoTest]: <arg" + i + ">"+cmdparams[i]+"</arg" + i + ">");
139 } 139 }
140 } 140 }
141 141
@@ -214,7 +214,7 @@ namespace OpenSim
214 { 214 {
215 base.RunCmd(command, cmdparams); 215 base.RunCmd(command, cmdparams);
216 RunPluginCommands(command , cmdparams); 216 RunPluginCommands(command , cmdparams);
217 217
218 switch (command) 218 switch (command)
219 { 219 {
220 case "clear-assets": 220 case "clear-assets":
@@ -255,7 +255,7 @@ namespace OpenSim
255 m_console.Notice(" debug scene [scripting] [collision] [physics] - Enable/Disable debug stuff, each can be True/False"); 255 m_console.Notice(" debug scene [scripting] [collision] [physics] - Enable/Disable debug stuff, each can be True/False");
256 m_console.Notice("edit-scale [prim name] [x] [y] [z] - resize given prim"); 256 m_console.Notice("edit-scale [prim name] [x] [y] [z] - resize given prim");
257 m_console.Notice("export-map [filename] - save image of world map"); 257 m_console.Notice("export-map [filename] - save image of world map");
258 m_console.Notice("force-update - force an update of prims in the scene"); 258 m_console.Notice("force-update - force an update of prims in the scene");
259 m_console.Notice("restart - disconnects all clients and restarts the sims in the instance."); 259 m_console.Notice("restart - disconnects all clients and restarts the sims in the instance.");
260 m_console.Notice("remove-region [name] - remove a region"); 260 m_console.Notice("remove-region [name] - remove a region");
261 m_console.Notice("load-xml [filename] - load prims from XML (DEPRECATED)"); 261 m_console.Notice("load-xml [filename] - load prims from XML (DEPRECATED)");
@@ -273,14 +273,14 @@ namespace OpenSim
273 m_console.Notice("config set section field value - set a config value"); 273 m_console.Notice("config set section field value - set a config value");
274 m_console.Notice("config get section field - get a config value"); 274 m_console.Notice("config get section field - get a config value");
275 m_console.Notice("config save - save OpenSim.ini"); 275 m_console.Notice("config save - save OpenSim.ini");
276 m_console.Notice("terrain help - show help for terrain commands."); 276 m_console.Notice("terrain help - show help for terrain commands.");
277 ShowPluginCommandsHelp(CombineParams(cmdparams, 0), m_console); 277 ShowPluginCommandsHelp(CombineParams(cmdparams, 0), m_console);
278 278
279 if (m_sandbox) 279 if (m_sandbox)
280 { 280 {
281 m_console.Notice(""); 281 m_console.Notice("");
282 m_console.Notice("create user - adds a new user."); 282 m_console.Notice("create user - adds a new user.");
283 } 283 }
284 284
285 break; 285 break;
286 286
@@ -314,11 +314,11 @@ namespace OpenSim
314 case "load-oar": 314 case "load-oar":
315 LoadOar(cmdparams); 315 LoadOar(cmdparams);
316 break; 316 break;
317 317
318 case "save-oar": 318 case "save-oar":
319 SaveOar(cmdparams); 319 SaveOar(cmdparams);
320 break; 320 break;
321 321
322 case "save-inv": 322 case "save-inv":
323 SaveInv(cmdparams); 323 SaveInv(cmdparams);
324 break; 324 break;
@@ -343,13 +343,13 @@ namespace OpenSim
343 break; 343 break;
344 344
345 case "create": 345 case "create":
346 Create(cmdparams); 346 Create(cmdparams);
347 break; 347 break;
348 348
349 case "create-region": 349 case "create-region":
350 CreateRegion(new RegionInfo(cmdparams[0], "Regions/" + cmdparams[1],false), true); 350 CreateRegion(new RegionInfo(cmdparams[0], "Regions/" + cmdparams[1],false), true);
351 break; 351 break;
352 352
353 case "remove-region": 353 case "remove-region":
354 string regName = CombineParams(cmdparams, 0); 354 string regName = CombineParams(cmdparams, 0);
355 355
@@ -441,7 +441,7 @@ namespace OpenSim
441 } 441 }
442 } 442 }
443 break; 443 break;
444 444
445 case "modules": 445 case "modules":
446 if (cmdparams.Length > 0) 446 if (cmdparams.Length > 0)
447 { 447 {
@@ -488,7 +488,7 @@ namespace OpenSim
488 m_commsManager.AddInventoryService(cmdparams[0]); 488 m_commsManager.AddInventoryService(cmdparams[0]);
489 } 489 }
490 break; 490 break;
491 491
492 default: 492 default:
493 string[] tmpPluginArgs = new string[cmdparams.Length + 1]; 493 string[] tmpPluginArgs = new string[cmdparams.Length + 1];
494 cmdparams.CopyTo(tmpPluginArgs, 1); 494 cmdparams.CopyTo(tmpPluginArgs, 1);
@@ -498,7 +498,7 @@ namespace OpenSim
498 break; 498 break;
499 } 499 }
500 } 500 }
501 501
502 /// <summary> 502 /// <summary>
503 /// Change the currently selected region. The selected region is that operated upon by single region commands. 503 /// Change the currently selected region. The selected region is that operated upon by single region commands.
504 /// </summary> 504 /// </summary>
@@ -515,13 +515,13 @@ namespace OpenSim
515 else 515 else
516 { 516 {
517 m_console.Error("Usage: change-region <region name>"); 517 m_console.Error("Usage: change-region <region name>");
518 } 518 }
519 519
520 string regionName = (m_sceneManager.CurrentScene == null ? "root" : m_sceneManager.CurrentScene.RegionInfo.RegionName); 520 string regionName = (m_sceneManager.CurrentScene == null ? "root" : m_sceneManager.CurrentScene.RegionInfo.RegionName);
521 m_console.Notice(String.Format("Currently selected region is {0}", regionName)); 521 m_console.Notice(String.Format("Currently selected region is {0}", regionName));
522 m_console.DefaultPrompt = String.Format("Region ({0}) ", regionName); 522 m_console.DefaultPrompt = String.Format("Region ({0}) ", regionName);
523 } 523 }
524 524
525 /// <summary> 525 /// <summary>
526 /// Execute switch for some of the create commands 526 /// Execute switch for some of the create commands
527 /// </summary> 527 /// </summary>
@@ -530,7 +530,7 @@ namespace OpenSim
530 { 530 {
531 if (args.Length == 0) 531 if (args.Length == 0)
532 return; 532 return;
533 533
534 switch (args[0]) 534 switch (args[0])
535 { 535 {
536 case "user": 536 case "user":
@@ -547,7 +547,7 @@ namespace OpenSim
547 { 547 {
548 if (args.Length == 0) 548 if (args.Length == 0)
549 return; 549 return;
550 550
551 switch (args[0]) 551 switch (args[0])
552 { 552 {
553 case "packet": 553 case "packet":
@@ -566,7 +566,7 @@ namespace OpenSim
566 } 566 }
567 567
568 break; 568 break;
569 569
570 case "scene": 570 case "scene":
571 if (args.Length == 4) 571 if (args.Length == 4)
572 { 572 {
@@ -580,11 +580,11 @@ namespace OpenSim
580 bool collisionsOn = !Convert.ToBoolean(args[2]); 580 bool collisionsOn = !Convert.ToBoolean(args[2]);
581 bool physicsOn = !Convert.ToBoolean(args[3]); 581 bool physicsOn = !Convert.ToBoolean(args[3]);
582 m_sceneManager.CurrentScene.SetSceneCoreDebug(scriptingOn, collisionsOn, physicsOn); 582 m_sceneManager.CurrentScene.SetSceneCoreDebug(scriptingOn, collisionsOn, physicsOn);
583 583
584 m_console.Notice( 584 m_console.Notice(
585 "CONSOLE", 585 "CONSOLE",
586 String.Format( 586 String.Format(
587 "Set debug scene scripting = {0}, collisions = {1}, physics = {2}", 587 "Set debug scene scripting = {0}, collisions = {1}, physics = {2}",
588 !scriptingOn, !collisionsOn, !physicsOn)); 588 !scriptingOn, !collisionsOn, !physicsOn));
589 } 589 }
590 } 590 }
@@ -592,9 +592,9 @@ namespace OpenSim
592 { 592 {
593 m_console.Error("debug scene <scripting> <collisions> <physics> (where inside <> is true/false)"); 593 m_console.Error("debug scene <scripting> <collisions> <physics> (where inside <> is true/false)");
594 } 594 }
595 595
596 break; 596 break;
597 597
598 default: 598 default:
599 m_console.Error("Unknown debug"); 599 m_console.Error("Unknown debug");
600 break; 600 break;
@@ -666,7 +666,7 @@ namespace OpenSim
666 break; 666 break;
667 } 667 }
668 } 668 }
669 669
670 /// <summary> 670 /// <summary>
671 /// Create a new user 671 /// Create a new user
672 /// </summary> 672 /// </summary>
@@ -697,7 +697,7 @@ namespace OpenSim
697 697
698 if ( cmdparams.Length < 6 ) 698 if ( cmdparams.Length < 6 )
699 regY = Convert.ToUInt32(MainConsole.Instance.CmdPrompt("Start Region Y", regY.ToString())); 699 regY = Convert.ToUInt32(MainConsole.Instance.CmdPrompt("Start Region Y", regY.ToString()));
700 else regY = Convert.ToUInt32(cmdparams[5]); 700 else regY = Convert.ToUInt32(cmdparams[5]);
701 701
702 if (null == m_commsManager.UserService.GetUserProfile(firstName, lastName)) 702 if (null == m_commsManager.UserService.GetUserProfile(firstName, lastName))
703 { 703 {
@@ -706,9 +706,9 @@ namespace OpenSim
706 else 706 else
707 { 707 {
708 m_log.ErrorFormat("[CONSOLE]: A user with the name {0} {1} already exists!", firstName, lastName); 708 m_log.ErrorFormat("[CONSOLE]: A user with the name {0} {1} already exists!", firstName, lastName);
709 } 709 }
710 } 710 }
711 711
712 protected void SaveXml(string[] cmdparams) 712 protected void SaveXml(string[] cmdparams)
713 { 713 {
714 m_log.Error("[CONSOLE]: PLEASE NOTE, save-xml is DEPRECATED and may be REMOVED soon. If you are using this and there is some reason you can't use save-xml2, please file a mantis detailing the reason."); 714 m_log.Error("[CONSOLE]: PLEASE NOTE, save-xml is DEPRECATED and may be REMOVED soon. If you are using this and there is some reason you can't use save-xml2, please file a mantis detailing the reason.");
@@ -721,8 +721,8 @@ namespace OpenSim
721 { 721 {
722 m_sceneManager.SaveCurrentSceneToXml(DEFAULT_PRIM_BACKUP_FILENAME); 722 m_sceneManager.SaveCurrentSceneToXml(DEFAULT_PRIM_BACKUP_FILENAME);
723 } 723 }
724 } 724 }
725 725
726 protected void LoadXml(string[] cmdparams) 726 protected void LoadXml(string[] cmdparams)
727 { 727 {
728 m_log.Error("[CONSOLE]: PLEASE NOTE, load-xml is DEPRECATED and may be REMOVED soon. If you are using this and there is some reason you can't use load-xml2, please file a mantis detailing the reason."); 728 m_log.Error("[CONSOLE]: PLEASE NOTE, load-xml is DEPRECATED and may be REMOVED soon. If you are using this and there is some reason you can't use load-xml2, please file a mantis detailing the reason.");
@@ -758,8 +758,8 @@ namespace OpenSim
758 { 758 {
759 m_sceneManager.LoadCurrentSceneFromXml(DEFAULT_PRIM_BACKUP_FILENAME, false, loadOffset); 759 m_sceneManager.LoadCurrentSceneFromXml(DEFAULT_PRIM_BACKUP_FILENAME, false, loadOffset);
760 } 760 }
761 } 761 }
762 762
763 protected void SaveXml2(string[] cmdparams) 763 protected void SaveXml2(string[] cmdparams)
764 { 764 {
765 if (cmdparams.Length > 0) 765 if (cmdparams.Length > 0)
@@ -771,7 +771,7 @@ namespace OpenSim
771 m_sceneManager.SaveCurrentSceneToXml2(DEFAULT_PRIM_BACKUP_FILENAME); 771 m_sceneManager.SaveCurrentSceneToXml2(DEFAULT_PRIM_BACKUP_FILENAME);
772 } 772 }
773 } 773 }
774 774
775 protected void LoadXml2(string[] cmdparams) 775 protected void LoadXml2(string[] cmdparams)
776 { 776 {
777 if (cmdparams.Length > 0) 777 if (cmdparams.Length > 0)
@@ -782,8 +782,8 @@ namespace OpenSim
782 { 782 {
783 m_sceneManager.LoadCurrentSceneFromXml2(DEFAULT_PRIM_BACKUP_FILENAME); 783 m_sceneManager.LoadCurrentSceneFromXml2(DEFAULT_PRIM_BACKUP_FILENAME);
784 } 784 }
785 } 785 }
786 786
787 /// <summary> 787 /// <summary>
788 /// Load a whole region from an opensim archive. 788 /// Load a whole region from an opensim archive.
789 /// </summary> 789 /// </summary>
@@ -800,9 +800,9 @@ namespace OpenSim
800 else 800 else
801 { 801 {
802 m_sceneManager.LoadArchiveToCurrentScene(DEFAULT_OAR_BACKUP_FILENAME); 802 m_sceneManager.LoadArchiveToCurrentScene(DEFAULT_OAR_BACKUP_FILENAME);
803 } 803 }
804 } 804 }
805 805
806 /// <summary> 806 /// <summary>
807 /// Save a region to a file, including all the assets needed to restore it. 807 /// Save a region to a file, including all the assets needed to restore it.
808 /// </summary> 808 /// </summary>
@@ -819,8 +819,8 @@ namespace OpenSim
819 else 819 else
820 { 820 {
821 m_sceneManager.SaveCurrentSceneToArchive(DEFAULT_OAR_BACKUP_FILENAME); 821 m_sceneManager.SaveCurrentSceneToArchive(DEFAULT_OAR_BACKUP_FILENAME);
822 } 822 }
823 } 823 }
824 824
825 private static string CombineParams(string[] commandParams, int pos) 825 private static string CombineParams(string[] commandParams, int pos)
826 { 826 {
@@ -835,7 +835,7 @@ namespace OpenSim
835 835
836 /// <summary> 836 /// <summary>
837 /// Runs the best matching plugin command 837 /// Runs the best matching plugin command
838 /// 838 ///
839 /// returns true if a match was found, false otherwise. 839 /// returns true if a match was found, false otherwise.
840 /// </summary> 840 /// </summary>
841 public bool RunPluginCommands(string cmd, string[] withParams) 841 public bool RunPluginCommands(string cmd, string[] withParams)
diff --git a/OpenSim/Region/Application/OpenSimBase.cs b/OpenSim/Region/Application/OpenSimBase.cs
index 0ac8cd7..983773a 100644
--- a/OpenSim/Region/Application/OpenSimBase.cs
+++ b/OpenSim/Region/Application/OpenSimBase.cs
@@ -70,7 +70,7 @@ namespace OpenSim
70 /// The file used to load and save an opensim archive if no filename has been specified 70 /// The file used to load and save an opensim archive if no filename has been specified
71 /// </summary> 71 /// </summary>
72 protected const string DEFAULT_OAR_BACKUP_FILENAME = "scene_oar.tar.gz"; 72 protected const string DEFAULT_OAR_BACKUP_FILENAME = "scene_oar.tar.gz";
73 73
74 /// <summary> 74 /// <summary>
75 /// The file to load and save inventory if no filename has been specified 75 /// The file to load and save inventory if no filename has been specified
76 /// </summary> 76 /// </summary>
@@ -161,7 +161,7 @@ namespace OpenSim
161 m_config = new OpenSimConfigSource(); 161 m_config = new OpenSimConfigSource();
162 m_config.Source = new IniConfigSource(); 162 m_config.Source = new IniConfigSource();
163 // IConfigSource icong; 163 // IConfigSource icong;
164 164
165 //check for .INI file (either default or name passed in command line) 165 //check for .INI file (either default or name passed in command line)
166 if (File.Exists(Application.iniFilePath)) 166 if (File.Exists(Application.iniFilePath))
167 { 167 {
@@ -338,7 +338,7 @@ namespace OpenSim
338 338
339 protected void LoadPlugins() 339 protected void LoadPlugins()
340 { 340 {
341 PluginLoader<IApplicationPlugin> loader = 341 PluginLoader<IApplicationPlugin> loader =
342 new PluginLoader<IApplicationPlugin> (new ApplicationPluginInitialiser (this)); 342 new PluginLoader<IApplicationPlugin> (new ApplicationPluginInitialiser (this));
343 343
344 loader.Load ("/OpenSim/Startup"); 344 loader.Load ("/OpenSim/Startup");
@@ -351,7 +351,7 @@ namespace OpenSim
351 public override void Startup() 351 public override void Startup()
352 { 352 {
353 base.Startup(); 353 base.Startup();
354 354
355 m_stats = StatsManager.StartCollectingSimExtraStats(); 355 m_stats = StatsManager.StartCollectingSimExtraStats();
356 356
357 // StandAlone mode? m_sandbox is determined by !startupConfig.GetBoolean("gridmode", false) 357 // StandAlone mode? m_sandbox is determined by !startupConfig.GetBoolean("gridmode", false)
@@ -586,7 +586,7 @@ namespace OpenSim
586 public void handleRestartRegion(RegionInfo whichRegion) 586 public void handleRestartRegion(RegionInfo whichRegion)
587 { 587 {
588 m_log.Error("[OPENSIM MAIN]: Got restart signal from SceneManager"); 588 m_log.Error("[OPENSIM MAIN]: Got restart signal from SceneManager");
589 589
590 // Shutting down the client server 590 // Shutting down the client server
591 bool foundClientServer = false; 591 bool foundClientServer = false;
592 int clientServerElement = 0; 592 int clientServerElement = 0;
@@ -660,7 +660,7 @@ namespace OpenSim
660 } 660 }
661 661
662 #endregion 662 #endregion
663 663
664 /// <summary> 664 /// <summary>
665 /// Save inventory to a file. 665 /// Save inventory to a file.
666 /// </summary> 666 /// </summary>
@@ -668,49 +668,49 @@ namespace OpenSim
668 protected void SaveInv(string[] cmdparams) 668 protected void SaveInv(string[] cmdparams)
669 { 669 {
670 m_log.Error("[CONSOLE]: This command has not yet been implemented!"); 670 m_log.Error("[CONSOLE]: This command has not yet been implemented!");
671 671
672 if (cmdparams.Length < 3) 672 if (cmdparams.Length < 3)
673 { 673 {
674 m_log.Error("[CONSOLE]: usage is save-inv <first name> <last name> <inventory path> [<save file path>]"); 674 m_log.Error("[CONSOLE]: usage is save-inv <first name> <last name> <inventory path> [<save file path>]");
675 return; 675 return;
676 } 676 }
677 677
678 string firstName = cmdparams[0]; 678 string firstName = cmdparams[0];
679 string lastName = cmdparams[1]; 679 string lastName = cmdparams[1];
680 string invPath = cmdparams[2]; 680 string invPath = cmdparams[2];
681 //string savePath = (cmdparams.Length > 3 ? cmdparams[3] : DEFAULT_INV_BACKUP_FILENAME); 681 //string savePath = (cmdparams.Length > 3 ? cmdparams[3] : DEFAULT_INV_BACKUP_FILENAME);
682 682
683 UserProfileData userProfile = m_commsManager.UserService.GetUserProfile(firstName, lastName); 683 UserProfileData userProfile = m_commsManager.UserService.GetUserProfile(firstName, lastName);
684 if (null == userProfile) 684 if (null == userProfile)
685 { 685 {
686 m_log.ErrorFormat("[CONSOLE]: Failed to find user {0} {1}", firstName, lastName); 686 m_log.ErrorFormat("[CONSOLE]: Failed to find user {0} {1}", firstName, lastName);
687 return; 687 return;
688 } 688 }
689 689
690 CachedUserInfo userInfo = m_commsManager.UserProfileCacheService.GetUserDetails(userProfile.ID); 690 CachedUserInfo userInfo = m_commsManager.UserProfileCacheService.GetUserDetails(userProfile.ID);
691 if (null == userInfo) 691 if (null == userInfo)
692 { 692 {
693 m_log.ErrorFormat("[CONSOLE]: Failed to find user info for {0} {1} {2}", firstName, lastName, userProfile.ID); 693 m_log.ErrorFormat("[CONSOLE]: Failed to find user info for {0} {1} {2}", firstName, lastName, userProfile.ID);
694 return; 694 return;
695 } 695 }
696 696
697 InventoryFolderImpl inventoryFolder = null; 697 InventoryFolderImpl inventoryFolder = null;
698 InventoryItemBase inventoryItem = null; 698 InventoryItemBase inventoryItem = null;
699 699
700 if (userInfo.HasReceivedInventory) 700 if (userInfo.HasReceivedInventory)
701 { 701 {
702 // Eliminate double slashes and any leading / on the path. This might be better done within InventoryFolderImpl 702 // Eliminate double slashes and any leading / on the path. This might be better done within InventoryFolderImpl
703 // itself (possibly at a small loss in efficiency). 703 // itself (possibly at a small loss in efficiency).
704 string[] components 704 string[] components
705 = invPath.Split(new string[] { InventoryFolderImpl.PATH_DELIMITER }, StringSplitOptions.RemoveEmptyEntries); 705 = invPath.Split(new string[] { InventoryFolderImpl.PATH_DELIMITER }, StringSplitOptions.RemoveEmptyEntries);
706 invPath = String.Empty; 706 invPath = String.Empty;
707 foreach (string c in components) 707 foreach (string c in components)
708 { 708 {
709 invPath += c + InventoryFolderImpl.PATH_DELIMITER; 709 invPath += c + InventoryFolderImpl.PATH_DELIMITER;
710 } 710 }
711 711
712 invPath = invPath.Remove(invPath.LastIndexOf(InventoryFolderImpl.PATH_DELIMITER)); 712 invPath = invPath.Remove(invPath.LastIndexOf(InventoryFolderImpl.PATH_DELIMITER));
713 713
714 // Annoyingly Split actually returns the original string if the input string consists only of delimiters 714 // Annoyingly Split actually returns the original string if the input string consists only of delimiters
715 // Therefore if we still start with a / after the split, then we need the root folder 715 // Therefore if we still start with a / after the split, then we need the root folder
716 if (invPath.StartsWith(InventoryFolderImpl.PATH_DELIMITER)) 716 if (invPath.StartsWith(InventoryFolderImpl.PATH_DELIMITER))
@@ -718,10 +718,10 @@ namespace OpenSim
718 inventoryFolder = userInfo.RootFolder; 718 inventoryFolder = userInfo.RootFolder;
719 } 719 }
720 else 720 else
721 { 721 {
722 inventoryFolder = userInfo.RootFolder.FindFolderByPath(invPath); 722 inventoryFolder = userInfo.RootFolder.FindFolderByPath(invPath);
723 } 723 }
724 724
725 // The path may point to an item instead 725 // The path may point to an item instead
726 if (inventoryFolder == null) 726 if (inventoryFolder == null)
727 { 727 {
@@ -733,7 +733,7 @@ namespace OpenSim
733 m_log.ErrorFormat("[CONSOLE]: Have not yet received inventory info for user {0} {1} {2}", firstName, lastName, userProfile.ID); 733 m_log.ErrorFormat("[CONSOLE]: Have not yet received inventory info for user {0} {1} {2}", firstName, lastName, userProfile.ID);
734 return; 734 return;
735 } 735 }
736 736
737 if (null != inventoryFolder) 737 if (null != inventoryFolder)
738 { 738 {
739 m_log.InfoFormat("[CONSOLE]: Found folder {0} {1} at {2}", inventoryFolder.Name, inventoryFolder.ID, invPath); 739 m_log.InfoFormat("[CONSOLE]: Found folder {0} {1} at {2}", inventoryFolder.Name, inventoryFolder.ID, invPath);
@@ -746,8 +746,8 @@ namespace OpenSim
746 { 746 {
747 m_log.ErrorFormat("[CONSOLE]: Could not find inventory entry at path {0}", invPath); 747 m_log.ErrorFormat("[CONSOLE]: Could not find inventory entry at path {0}", invPath);
748 return; 748 return;
749 } 749 }
750 } 750 }
751 751
752 /// <summary> 752 /// <summary>
753 /// Performs any last-minute sanity checking and shuts down the region server 753 /// Performs any last-minute sanity checking and shuts down the region server