From 7c50651cd12eaa5830d8b17c07786f1f497ddca9 Mon Sep 17 00:00:00 2001 From: UbitUmarov Date: Sat, 26 May 2018 03:35:56 +0100 Subject: [PATCH] add a check to data_exposure option of DataSnapshot module --- .../OptionalModules/DataSnapshot/DataSnapshotManager.cs | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/OpenSim/Region/OptionalModules/DataSnapshot/DataSnapshotManager.cs b/OpenSim/Region/OptionalModules/DataSnapshot/DataSnapshotManager.cs index fd841d45dc..dae78d216a 100644 --- a/OpenSim/Region/OptionalModules/DataSnapshot/DataSnapshotManager.cs +++ b/OpenSim/Region/OptionalModules/DataSnapshot/DataSnapshotManager.cs @@ -127,7 +127,15 @@ namespace OpenSim.Region.DataSnapshot m_gridinfo.Add( "name", config.Configs["DataSnapshot"].GetString("gridname", "the lost continent of hippo")); + m_exposure_level = config.Configs["DataSnapshot"].GetString("data_exposure", m_exposure_level); + m_exposure_level = m_exposure_level.ToLower(); + if(m_exposure_level !="all" && m_exposure_level != "minimum") + { + m_log.ErrorFormat("[DATASNAPSHOT]: unknown data_exposure option: '{0}'. defaulting to minimum",m_exposure_level); + m_exposure_level = "minimum"; + } + m_period = config.Configs["DataSnapshot"].GetInt("default_snapshot_period", m_period); m_maxStales = config.Configs["DataSnapshot"].GetInt("max_changes_before_update", m_maxStales); m_snapsDir = config.Configs["DataSnapshot"].GetString("snapshot_cache_directory", m_snapsDir);