diff options
Diffstat (limited to 'OpenSim')
-rw-r--r-- | OpenSim/Services/FSAssetService/FSAssetService.cs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/OpenSim/Services/FSAssetService/FSAssetService.cs b/OpenSim/Services/FSAssetService/FSAssetService.cs index d1a59d1..f130c20 100644 --- a/OpenSim/Services/FSAssetService/FSAssetService.cs +++ b/OpenSim/Services/FSAssetService/FSAssetService.cs | |||
@@ -185,7 +185,18 @@ namespace OpenSim.Services.FSAssetService | |||
185 | throw new Exception("Configuration error"); | 185 | throw new Exception("Configuration error"); |
186 | } | 186 | } |
187 | 187 | ||
188 | // OSGrid format is /3/3/, OpenSims default format is /2/2/2/4/. Try to figure out which we have. | ||
189 | List<string> dirs = new List<string>(Directory.EnumerateDirectories(m_FSBase)); | ||
190 | foreach (var dir in dirs) | ||
191 | { | ||
192 | if (3 == dir.Substring(dir.LastIndexOf(Path.DirectorySeparatorChar) + 1).Length) | ||
193 | { | ||
194 | m_useOsgridFormat = true; | ||
195 | break; | ||
196 | } | ||
197 | } | ||
188 | m_useOsgridFormat = assetConfig.GetBoolean("UseOsgridFormat", m_useOsgridFormat); | 198 | m_useOsgridFormat = assetConfig.GetBoolean("UseOsgridFormat", m_useOsgridFormat); |
199 | m_log.InfoFormat("[FSASSETS]: UseOsgridFormat is {0}", m_useOsgridFormat); | ||
189 | 200 | ||
190 | // Default is to show stats to retain original behaviour | 201 | // Default is to show stats to retain original behaviour |
191 | m_showStats = assetConfig.GetBoolean("ShowConsoleStats", m_showStats); | 202 | m_showStats = assetConfig.GetBoolean("ShowConsoleStats", m_showStats); |