From d54aac41d296f4ba74ef5f9a33bfd25a86cc198b Mon Sep 17 00:00:00 2001 From: Teravus Ovares Date: Fri, 10 Jul 2009 21:47:54 +0000 Subject: * Added a user friendly message to the sqlite regionsettings saver giving them troubleshooting options and telling them to restart the simulator. This situation, hopefully is temporary and generates an exception when sqlite users first start OpenSimulator because of an unexpected condition in the database layer. Restart and all is well. * Added a user friendly message to the 'No IInventoryService available' condition with troubleshooting options. --- OpenSim/Data/SQLite/SQLiteRegionData.cs | 18 +++++++++++++++++- 1 file changed, 17 insertions(+), 1 deletion(-) (limited to 'OpenSim/Data/SQLite/SQLiteRegionData.cs') diff --git a/OpenSim/Data/SQLite/SQLiteRegionData.cs b/OpenSim/Data/SQLite/SQLiteRegionData.cs index b3687de..16a05af 100644 --- a/OpenSim/Data/SQLite/SQLiteRegionData.cs +++ b/OpenSim/Data/SQLite/SQLiteRegionData.cs @@ -719,7 +719,23 @@ namespace OpenSim.Data.SQLite terrainDa.Update(ds, "terrain"); landDa.Update(ds, "land"); landAccessListDa.Update(ds, "landaccesslist"); - regionSettingsDa.Update(ds, "regionsettings"); + try + { + regionSettingsDa.Update(ds, "regionsettings"); + } + catch (SqliteExecutionException SqlEx) + { + if (SqlEx.Message.Contains("logic error")) + { + throw new Exception( + "There was a SQL error or connection string configuration error when saving the region settings. This could be a bug, it could also happen if ConnectionString is defined in the [DatabaseService] section of StandaloneCommon.ini in the config_include folder. This could also happen if the config_include folder doesn't exist or if the OpenSim.ini [Architecture] section isn't set. If this is your first time running OpenSimulator, please restart the simulator and bug a developer to fix this!", + SqlEx); + } + else + { + throw SqlEx; + } + } ds.AcceptChanges(); } } -- cgit v1.1