diff --git a/OpenSim/Framework/PluginManager.cs b/OpenSim/Framework/PluginManager.cs index 23d594598a..00263f514f 100644 --- a/OpenSim/Framework/PluginManager.cs +++ b/OpenSim/Framework/PluginManager.cs @@ -92,6 +92,7 @@ namespace OpenSim.Framework // Attempt to install the plugin disabled if (Install(ps, pack) == true) { + MainConsole.Instance.Output("Ignore the following error..."); PluginRegistry.Update(ps); Addin addin = PluginRegistry.GetAddin(aentry.Addin.Id); PluginRegistry.DisableAddin(addin.Id); @@ -479,6 +480,7 @@ namespace OpenSim.Framework ConsoleProgressStatus ps = new ConsoleProgressStatus(false); if (!AddinManager.AddinEngine.IsAddinLoaded(addin.Id)) { + MainConsole.Instance.Output("Ignore the following error..."); AddinManager.Registry.Rebuild(ps); AddinManager.AddinEngine.LoadAddin(ps, addin.Id); } diff --git a/OpenSim/Server/Base/ServerUtils.cs b/OpenSim/Server/Base/ServerUtils.cs index 31b04465b6..d06d612a2d 100644 --- a/OpenSim/Server/Base/ServerUtils.cs +++ b/OpenSim/Server/Base/ServerUtils.cs @@ -89,12 +89,39 @@ namespace OpenSim.Server.Base Config = config; Registry = new AddinRegistry(registryPath, "."); + suppress_console_output_(true); AddinManager.Initialize(registryPath); + suppress_console_output_(false); AddinManager.Registry.Update(); CommandManager commandmanager = new CommandManager(Registry); AddinManager.AddExtensionNodeHandler("/Robust/Connector", OnExtensionChanged); } + private static TextWriter prev_console_; + // Temporarily masking the errors reported on start + // This is caused by a non-managed dll in the ./bin dir + // when the registry is initialized. The dll belongs to + // libomv, which has a hard-coded path to "." for pinvoke + // to load the openjpeg dll + // + // Will look for a way to fix, but for now this keeps the + // confusion to a minimum. this was copied from our region + // plugin loader, we have been doing this in there for a long time. + // + public void suppress_console_output_(bool save) + { + if (save) + { + prev_console_ = System.Console.Out; + System.Console.SetOut(new StreamWriter(Stream.Null)); + } + else + { + if (prev_console_ != null) + System.Console.SetOut(prev_console_); + } + } + private void OnExtensionChanged(object s, ExtensionNodeEventArgs args) { IRobustConnector connector = (IRobustConnector)args.ExtensionObject;